Bonjour,
je travaille actuellement sur Oscommerce ,
j'ai rajouté une contribution "Manufacturer 2".
Il y a une requete qui bloque puisque la requete n'est pas compatible Mysql 5 et que mon serveur est sous Mysql 5.
voici la requete :
et voici le message d'erreur :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23 $listing_sql = "select " . $select_column_list . " p.products_id, p.manufacturers2_id, p.products_price, p.products_tax_class_id, IF(s.status, s.specials_new_products_price, NULL) as specials_new_products_price, IF(s.status, s.specials_new_products_price, p.products_price) as final_price from " . TABLE_PRODUCTS . " p left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id , " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_MANUFACTURERS2 . " m, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c where p.products_status = '1' and p.manufacturers2_id = m.manufacturers2_id and m.manufacturers2_id = '" . (int)$HTTP_GET_VARS['manufacturers2_id'] . "' and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and pd.language_id = '" . (int)$languages_id . "' and p2c.categories_id = '" . (int)$HTTP_GET_VARS['filter_id'] . "'";
Ou est l'erreur dans la requete ?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 'select p.products_image, pd.products_name, p.products_weight, p.products_id, p.' at line 1
select count(p.products_id) as total select p.products_image, pd.products_name, p.products_weight, p.products_id, p.manufacturers2_id, p.products_price, p.products_tax_class_id, IF(s.status, s.specials_new_products_price, NULL) as specials_new_products_price, IF(s.status, s.specials_new_products_price, p.products_price) as final_price from products p left join specials s on p.products_id = s.products_id , products_description pd, manufacturers2 m, products_to_categories p2c where p.products_status = '1' and p.manufacturers2_id = m.manufacturers2_id and m.manufacturers2_id = '12' and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and pd.language_id = '1' and p2c.categories_id = '21'![]()
merci d'avance
Partager