Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

New Error in Admin Occuring when 0 Results


Recommended Posts

Hi All,


this just starting happening today and I am not sure why?


It seems that on the list for admin/orders.php and admin/customers.php when the results of a query is Zero I get my sql query turning the limit into a negative and an error results.


For example if I am searching for a customer in admin/customers.php and they do not exist I get the following error. Notice the - sign before the limit number.


select c.customers_id, c.customers_lastname, c.customers_firstname, c.customers_email_address, a.entry_country_id from customers c left join address_book a on c.customers_id = a.customers_id and c.customers_default_address_id = a.address_book_id where c.customers_lastname like '%jenson%' or c.customers_firstname like '%jenson%' or c.customers_email_address like '%jenson%' order by c.customers_lastname, c.customers_firstname limit -50, 50


but when I search whith a name that is acutally in the database It is listing it properly.


Also this is occuring on orders.php, say when i select a status to show that do not have any orders linked to it.


Any ideas? I know the split page results uses the $order_query_raw_numrows but how to prevent the division by zero and the resulting minus sign?



Link to comment
Share on other sites


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

  • Create New...