Results 1 to 3 of 3
  1. #1
    Join Date
    Mar 2005
    Posts
    167
    Plugin Contributions
    0

    Default Division by zero error

    Anyone know what may be causing this issue?

    On my main page beneath the categories it shows
    - New products
    - All products

    When I click all products a list of all my products shows but when I click on new products I get the following error:

    Warning: Division by zero in /home/simetra/public_html/includes/classes/split_page_results.php on line 76

    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 '-0, 0' at line 10
    in:
    [SELECT p.products_id, p.products_type, pd.products_name, p.products_image, p.products_price, p.products_tax_class_id, p.products_date_added, m.manufacturers_name, p.products_model, p.products_quantity, p.products_weight, p.product_is_call, p.product_is_always_free_shipping, p.products_qty_box_status FROM products p LEFT JOIN manufacturers m ON (p.manufacturers_id = m.manufacturers_id), products_description pd WHERE p.products_status = 1 AND p.products_id = pd.products_id AND pd.language_id = 1 and p.products_date_added >=20070628 order by p.products_date_added DESC, pd.products_name limit -0, 0]

    Any thoughts?

  2. #2
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: Division by zero error

    What version of Zen Cart ?
    What addons/contributions are installed?
    Do you have any "0" values under Admin->Config->Maximum Values ?
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Mar 2005
    Posts
    167
    Plugin Contributions
    0

    Default Re: Division by zero error

    You rock! I had a 0 in the max value for new products. Duh me!

    Thank you SO much!

 

 

Similar Threads

  1. Division by Zero error
    By sinecurea in forum General Questions
    Replies: 4
    Last Post: 11 Sep 2007, 05:23 PM
  2. Error : Division by zero.....
    By artisticleaf in forum Installing on a Linux/Unix Server
    Replies: 6
    Last Post: 10 Sep 2007, 08:03 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR