mpimpi 0 Posted February 17, 2020 Posted February 17, 2020 Bonjour, J'utilise Prestashop 1.6.1.24 pour mon site www.nechri.tn J'ai un peu moins de 400 articles.J'essaie de faire la réindexation pour la recherche mais ça ne fonctionne pas. Au départ, j'ai "Produits indexés 0 / 233.". Je lance "Ajouter à l'index les produits manquants" ou "Reconstruire l'index". Rien ne se passe. Après x minutes, je reçoit un page introuvable et le nombre de produits indexés est toujours à 0.. Avec Debug, j'ai tout de suite une erreur: Fatal error: Uncaught Can't update table 'ps_product_shop' in stored function/trigger because it is already used by statement which invoked this stored function/trigger. <br /><br /> <pre> UPDATE `ps_product` p INNER JOIN ps_product_shop product_shop ON (product_shop.id_product = p.id_product AND product_shop.id_shop = 1) SET p.`indexed` = 0, product_shop.`indexed` = 0 WHERE product_shop.`visibility` IN ("both", "search") AND product_shop.`active` = 1 AND product_shop.`indexed` = 0 </pre> thrown in /home/nechritn/public_html/classes/db/Db.php on line 791 Quelqu'un pourrait-il m'aider? Merci d'avance et bonne journée, Marc Share this post Link to post Share on other sites
Mediacom87 1,333 Posted February 17, 2020 Posted February 17, 2020 Bonjour, Merci de renseigner un vrai sujet à votre demande et préciser des éléments indispensables. Share this post Link to post Share on other sites
doekia 1,503 Posted February 17, 2020 Posted February 17, 2020 Tu as visiblement un trigger sur ta table ... ce n'est pas standard. Il s'agit donc d'un ajout par un module tiers Share this post Link to post Share on other sites
mpimpi 0 Posted February 20, 2020 Posted February 20, 2020 Bonjour et merci pour votre réponse. Les infos Installation il y a un an. PS 1.6.1.24 (le problème existait avant la mise-à-jour.) www.nechri.tn thème Default Bootstrap modifié Code: quelques modifications mineures Hébergement vip_gold serveur cl-t224-062cl (?) PHP 5.6.40 MySQL 5.7.29 Navigateur Chrome Version 79.0.3945.130 (Build officiel) (64 bits) Le sujet est : "Recherche - Reconstruire l'Index". Je ne vois pas où je peux le modifier... Merci encore et bonne journée, Marc Share this post Link to post Share on other sites
mpimpi 0 Posted February 20, 2020 Posted February 20, 2020 On 2/17/2020 at 11:09 AM, doekia said: Tu as visiblement un trigger sur ta table ... ce n'est pas standard. Il s'agit donc d'un ajout par un module tiers Bonjour et merci pour ta réponse. J'ai cherché dans la DB, je n'ai trouvé ni trigger, ni fonction, ni procedure. Bonne journée, Marc Share this post Link to post Share on other sites
doekia 1,503 Posted February 20, 2020 Posted February 20, 2020 Le 2/17/2020 à 9:47 AM, mpimpi a dit : Fatal error: Uncaught Can't update table 'ps_product_shop' in stored function/trigger because it is already used by statement which invoked this stored function/trigger. il y a une heure, mpimpi a dit : J'ai cherché dans la DB, je n'ai trouvé ni trigger, ni fonction, ni procedure. L'un de vous 2 se trompe donc... honnêtement je pense plutôt que c'est toi Share this post Link to post Share on other sites
mpimpi 0 Posted February 20, 2020 Posted February 20, 2020 1 hour ago, doekia said: L'un de vous 2 se trompe donc... honnêtement je pense plutôt que c'est toi Ca serait possible que je me trompe? Heu. En fait, j'ai trouvé un trigger after update sur la table ps_product: CREATE TRIGGER `price_update` AFTER UPDATE ON `ps_product` FOR EACH ROW UPDATE ps_product_shop SET price = NEW.price WHERE id_product = NEW.id_product Je l'ai supprimé, j'ai relancé l'indexation. Et ça marche!!! Merci, merci et encore merci.... Cela dit, je ne me souviens pas si ce trigger était là d'origine ou si c'est moi qui l'ai créé... Bonne journée, Marc Share this post Link to post Share on other sites
doekia 1,503 Posted February 20, 2020 Posted February 20, 2020 ça n'existe pas nativement dans prestashop. Share this post Link to post Share on other sites
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now