Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

MySQL Error in Orders Section of Admin


InFXnet.com

Recommended Posts

Posted

Hi,

 

The shop has been running for a little while and has taken a couple of orders. Since completing the data return part of the PayPal setup process we have an error when trying to view Orders in the Admin section of OSc 2.2 and several other areas - the problem seems to be common though:

 

Reviews

1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '-4, 4' at line 1

 

select reviews_id, products_id, date_added, last_modified, reviews_rating from reviews order by date_added DESC limit -4, 4

 

[TEP STOP]

 

Specials

1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '-4, 4' at line 1

 

select p.products_id, pd.products_name, p.products_price, s.specials_id, s.specials_new_products_price, s.specials_date_added, s.specials_last_modified, s.expires_date, s.date_status_change, s.status from products p, specials s, products_description pd where p.products_id = pd.products_id and pd.language_id = '1' and p.products_id = s.products_id order by pd.products_name limit -4, 4

 

[TEP STOP]

 

Orders

Order ID:

Status:

1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '-4, 4' at line 1

 

select o.orders_id, o.customers_name, o.payment_method, o.date_purchased, o.last_modified, o.currency, o.currency_value, s.orders_status_name, ot.text as order_total from orders o left join orders_total ot on (o.orders_id = ot.orders_id), orders_status s where o.orders_status = s.orders_status_id and s.language_id = '1' and ot.class = 'ot_total' order by o.orders_id DESC limit -4, 4

 

[TEP STOP]

 

 

Thank you in advance for any help offered. :-)

Posted
This is a known issue. I can't remember the solution off the top of my head, but if you search the forums you will find the answer fairly quickly. Try searching for mySQL and limit near error.

 

Hi, I've tried and failed again to find a reference similar enough for me apply the solution, any guidance to the appropriate thread would be appreciated :-)

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...