I took the sql statement from my sql log which received the error and made a couple minor modifications (based on my earlier post) and tested it in phpmyadmin and the sql statements worked. See below for the before and after sql statements.
Note, the only differences are the parenphises around the from clause and the on clause. With this insight I would think that this fix should be fairly simple. Thanks in advance.
FROM (products, products_description, products_to_categories)
LEFT JOIN specials ON ( products.products_id = specials.products_id )
Before
select products.products_id, products.products_quantity, products.products_model, products.products_price, products.products_weight, products.manufacturers_id, products_description.products_name, products.products_status, products_description.products_description, products_description.products_url, products.products_image, specials.specials_new_products_price, products_description.language_id, products.products_tax_class_id, products_description.products_viewed, DATE_FORMAT(products.products_date_available, "%Y-%m-%d %H:%i:%S"), DATE_FORMAT(products.products_date_added, "%Y-%m-%d %H:%i:%S"), DATE_FORMAT(products.products_last_modified, "%Y-%m-%d %H:%i:%S") from products, products_description, products_to_categories left join specials ON products.products_id = specials.products_id where products.products_id=products_description.products_id and products_to_categories.products_id=products.products_id and products_to_categories.categories_id=21 order by products_description.products_name
After
SELECT products.products_id, products.products_quantity, products.products_model, products.products_price, products.products_weight, products.manufacturers_id, products_description.products_name, products.products_status, products_description.products_description, products_description.products_url, products.products_image, specials.specials_new_products_price, products_description.language_id, products.products_tax_class_id, products_description.products_viewed, DATE_FORMAT( products.products_date_available, "%Y-%m-%d %H:%i:%S" ) , DATE_FORMAT( products.products_date_added, "%Y-%m-%d %H:%i:%S" ) , DATE_FORMAT( products.products_last_modified, "%Y-%m-%d %H:%i:%S" )
FROM (products, products_description, products_to_categories)
LEFT JOIN specials ON ( products.products_id = specials.products_id )
WHERE products.products_id = products_description.products_id
AND products_to_categories.products_id = products.products_id
AND products_to_categories.categories_id =21
ORDER BY products_description.products_name
LIMIT 0 , 30
|
|