Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

1064 Error SQL


Guest

Recommended Posts

Posted

Hi

 

I have deleted all preset manufacturers in Admin so I can install my own and now I have the following error message :

 

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]

 

Can anybody help to solve this please ?

 

Thanks in advance

 

Tom

Posted
Hi

 

I have deleted all preset manufacturers in Admin so I can install my own and now I have the following error message :

 

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]

 

Can anybody help to solve this please ?

 

Thanks in advance

 

Tom

 

Hi

 

For anybody in the future this is the answer to this common proble :

 

Hi, Below is the code from the latest version of osCommerce, and if you have that code then you should be okay (admin/includes/classes/split_page_resuts.php line 37):

 

$offset = ($max_rows_per_page * ($current_page_number - 1));

$sql_query .= " limit " . max($offset, 0) . ", " . $max_rows_per_page;

}

 

There is also the includes/classes/split_page_results.php file to consider.

 

Tom

Posted

Tom, by all emans add the security patches to your shop!!! there have been 3 in the last year. They are all listed in a special update file when you download the current version of osC from this site.

:-)

Monika

 

addicted to writing code ... can't get enough of databases either, LOL!

 

my toolbox: Textpad - Compare and Merge - phpMyAdmin - WS_FTP - Photoshop - How to search the forum

 

Interactive Media Award July 2007 ~ category E-Commerce

my advice on the forum is for free, PMs where you send me work are considered consultation which I charge for ...

Archived

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

×
×
  • Create New...