Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

SQL syntax error 1064 - admin access 2.1, STS


faeries_requiem

Recommended Posts

I've just installed Admin Access 2.1. I also have STS installed.

 

Everything was working fine after installed Admin Access. I accessed the admin control panel, and started to configure aspects of my shop. I started by altering the currencies - all worked fine. I then went to remove all the manufacturer names. As soon as I'd deleted the last manufacturer, this code appeared:

 

Under admin panel > catalog > manufacturers

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 '-20, 20' at line 1

select manufacturers_id, manufacturers_name, manufacturers_image, date_added, last_modified from manufacturers order by manufacturers_name limit -20, 20

[TEP STOP]

 

So I tested the other pages, to see if they worked. Most of them did, apart from the following (I've included the error codes of each page).

 

Under admin panel > catalog > 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 '-20, 20' at line 1

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

[TEP STOP]

 

Under admin panel > catalog > 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 '-20, 20' 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 -20, 20

[TEP STOP]

 

Under admin panel > catalog > products expected

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 '-20, 20' at line 1

select pd.products_id, pd.products_name, p.products_date_available from products_description pd, products p where p.products_id = pd.products_id and p.products_date_available != '' and pd.language_id = '1' order by p.products_date_available DESC limit -20, 20

[TEP STOP]

 

Under admin panel > customers > orders

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 '-20, 20' 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 -20, 20

[TEP STOP]

 

Under admin panel > reports > products viewed

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 '-20, 20' at line 1

select p.products_id, pd.products_name, pd.products_viewed, l.name from products p, products_description pd, languages l where p.products_id = pd.products_id and l.languages_id = pd.language_id order by pd.products_viewed DESC limit -20, 20

[TEP STOP]

 

Under admin panel > reports > products purchased

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 '-20, 20' at line 1

select p.products_id, p.products_ordered, pd.products_name from products p, products_description pd where pd.products_id = p.products_id and pd.language_id = '1' and p.products_ordered > 0 group by pd.products_id order by p.products_ordered DESC, pd.products_name limit -20, 20

[TEP STOP]

 

Under admin panel > reports > customer orders total

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 '-20, 20' at line 1

select c.customers_firstname, c.customers_lastname, sum(op.products_quantity * op.final_price) as ordersum from customers c, orders_products op, orders o where c.customers_id = o.customers_id and o.orders_id = op.orders_id group by c.customers_firstname, c.customers_lastname order by ordersum DESC limit -20, 20

[TEP STOP]

 

 

I'm a complete SQL/MySQL and PHP newbie. So any help I could get is highly appreciated, as I really need to fix this :(

 

Thank you in advance to those who reply.

 

Requiem

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...