{"action":"closed","issue":{"url":"https://api.github.com/repos/PrestaShop/PrestaShop/issues/11159","repository_url":"https://api.github.com/repos/PrestaShop/PrestaShop","labels_url":"https://api.github.com/repos/PrestaShop/PrestaShop/issues/11159/labels{/name}","comments_url":"https://api.github.com/repos/PrestaShop/PrestaShop/issues/11159/comments","events_url":"https://api.github.com/repos/PrestaShop/PrestaShop/issues/11159/events","html_url":"https://github.com/PrestaShop/PrestaShop/issues/11159","id":374178766,"node_id":"MDU6SXNzdWUzNzQxNzg3NjY=","number":11159,"title":"Bad SQL query PS 1.7.4.3 multishop","user":{"login":"BenTen","id":915869,"node_id":"MDQ6VXNlcjkxNTg2OQ==","avatar_url":"https://avatars1.githubusercontent.com/u/915869?v=4","gravatar_id":"","url":"https://api.github.com/users/BenTen","html_url":"https://github.com/BenTen","followers_url":"https://api.github.com/users/BenTen/followers","following_url":"https://api.github.com/users/BenTen/following{/other_user}","gists_url":"https://api.github.com/users/BenTen/gists{/gist_id}","starred_url":"https://api.github.com/users/BenTen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BenTen/subscriptions","organizations_url":"https://api.github.com/users/BenTen/orgs","repos_url":"https://api.github.com/users/BenTen/repos","events_url":"https://api.github.com/users/BenTen/events{/privacy}","received_events_url":"https://api.github.com/users/BenTen/received_events","type":"User","site_admin":false},"labels":[{"id":984878719,"node_id":"MDU6TGFiZWw5ODQ4Nzg3MTk=","url":"https://api.github.com/repos/PrestaShop/PrestaShop/labels/CO","name":"CO","color":"444444","default":false},{"id":984888535,"node_id":"MDU6TGFiZWw5ODQ4ODg1MzU=","url":"https://api.github.com/repos/PrestaShop/PrestaShop/labels/NMI","name":"NMI","color":"ff8800","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2018-10-26T00:07:19Z","updated_at":"2018-10-30T07:50:20Z","closed_at":"2018-10-30T07:50:20Z","author_association":"NONE","body":"**Describe the bug**\r\nI have a bug in my website in url without the slash in the end of the main category.\r\n\r\nI get an fatal error when I remove the slash in the end of the main category.\r\n\r\n- https://example.com/en/category/ _(ok)_\r\n- https://example.com/en/category _(fatal error)_\r\n\r\n` Fatal error: Uncaught Unknown column 'pl.id_shop' in 'where clause'<br /><br /><pre>SELECT `id_product` FROM `ps_product_lang` WHERE `link_rewrite` = 'cat1' AND `id_lang` = 1 AND pl.`id_shop` = 1 LIMIT 1</pre> thrown in /classes/db/Db.php on line 746 `\r\n\r\nI posted on the forum, and a member said it's because a clean url module.\r\n\r\n**But he said too, there is a problem with the SQL query of Prestashop.**\r\nhttps://www.prestashop.com/forums/topic/912064-probleme-url-avec-et-sans-slash/?do=findComment&comment=2991656 (french)\r\n\r\nSo I post here not for my issue but for this SQL query.\r\n\r\n`SELECT `id_product` FROM `ps_product_lang` WHERE `link_rewrite` = 'cat1' AND `id_lang` = 1 AND pl.`id_shop` = 1 LIMIT 1`\r\n\r\nshould be\r\n\r\n`SELECT `id_product` FROM `ps_product_lang` WHERE `link_rewrite` = 'cat1' AND `id_lang` = 1 AND `id_shop` = 1 LIMIT 1`\r\n\r\nor\r\n\r\n`SELECT `id_product` FROM `ps_product_lang` pl WHERE `link_rewrite` = 'cat1' AND `id_lang` = 1 AND pl.`id_shop` = 1 LIMIT 1 `\r\n\r\n**Additionnal information**\r\nPrestaShop version: 1.7.4.3 multishop\r\nPHP version: 7.2\r\n"}}
{"actor":{"display_login":"khouloudbelguith"}}