Jump to content

Edit History

Antakarana

Antakarana

Hi!!!

I have a similar problem ona a PS 1.7.6.7 shop

search bar doesnt work... actualy it only shows manufacturer results, but it doesnt show any product results.

When activating debug mode it shows this error code when I perform any search:

 

 

[PrestaShopDatabaseException]

Key 'id_product' doesn't exist in table 'product_attribute_shop'<br /><br /><pre>SELECT p.*, product_shop.*, stock.out_of_stock, IFNULL(stock.quantity, 0) as quantity, pl.`description_short`, pl.`available_now`, pl.`available_later`, pl.`link_rewrite`, pl.`name`, image_shop.`id_image` id_image, il.`legend`, m.`name` manufacturer_name ,( SELECT SUM(weight) FROM prstshp_search_word sw LEFT JOIN prstshp_search_index si ON sw.id_word = si.id_word WHERE sw.id_lang = 1 AND sw.id_shop = 1 AND si.id_product = p.id_product AND (sw.word LIKE '%moet%') ) position, DATEDIFF( p.`date_add`, DATE_SUB( "2020-08-27 00:00:00", INTERVAL 150 DAY ) ) > 0 new, product_attribute_shop.minimal_quantity AS product_attribute_minimal_quantity, IFNULL(product_attribute_shop.`id_product_attribute`,0) id_product_attribute FROM prstshp_product p INNER JOIN prstshp_product_shop product_shop ON (product_shop.id_product = p.id_product AND product_shop.id_shop = 1) INNER JOIN `prstshp_product_lang` pl ON ( p.`id_product` = pl.`id_product` AND pl.`id_lang` = 1 AND pl.id_shop = 1 ) LEFT JOIN `prstshp_product_attribute_shop` product_attribute_shop FORCE INDEX (id_product) ON (p.`id_product` = product_attribute_shop.`id_product` AND product_attribute_shop.`default_on` = 1 AND product_attribute_shop.id_shop=1) LEFT JOIN prstshp_stock_available stock ON (stock.id_product = `p`.id_product AND stock.id_product_attribute = 0 AND stock.id_shop = 1 AND stock.id_shop_group = 0 ) LEFT JOIN `prstshp_manufacturer` m FORCE INDEX (PRIMARY) ON m.`id_manufacturer` = p.`id_manufacturer` LEFT JOIN `prstshp_image_shop` image_shop FORCE INDEX (id_product) ON (image_shop.`id_product` = p.`id_product` AND image_shop.cover=1 AND image_shop.id_shop=1) LEFT JOIN `prstshp_image_lang` il ON (image_shop.`id_image` = il.`id_image` AND il.`id_lang` = 1) WHERE p.`id_product` IN (3718,4214,5271,5313,5585,5586,5587) GROUP BY product_shop.id_product ORDER BY position desc LIMIT 0,24</pre>
at line 769 in file classes/db/Db.php

 

image.thumb.png.babfd324d1dd7020edbc0a62a9690ca5.png 

 

DbCore->displayError - [line 385 - classes/db/Db.php] - [1 Arguments]

DbCore->query - [line 613 - classes/db/Db.php] - [1 Arguments]

DbCore->executeS - [line 374 - classes/Search.php] - [3 Arguments]

SearchCore::find - [line 85 - src/Adapter/Search/SearchProductSearchProvider.php] - [9 Arguments]

PrestaShop\PrestaShop\Adapter\Search\SearchProductSearchProvider->runQuery - [line 308 - classes/controller/ProductListingFrontController.php] - [2 Arguments]

ProductListingFrontControllerCore->getProductSearchVariables - [line 580 - classes/controller/ProductListingFrontController.php]

ProductListingFrontControllerCore->doProductSearch - [line 82 - controllers/front/listing/SearchController.php] - [2 Arguments]

SearchControllerCore->initContent - [line 292 - classes/controller/Controller.php]

ControllerCore->run - [line 515 - classes/Dispatcher.php]

DispatcherCore->dispatch - [line 28 - index.php]

 

Can anybody help me?? 🙄

thanks in advace

Antakarana

Antakarana

Hi!!!

I have a similar problem ona a PS 1.7.6.7 shop

search bar doesnt work... actualy it only shows manufacturer results, but it doesnt show any product results.

When activating debug mode it shows this error code when I perform any search:

 

 

[PrestaShopDatabaseException]

Key 'id_product' doesn't exist in table 'product_attribute_shop'<br /><br /><pre>SELECT p.*, product_shop.*, stock.out_of_stock, IFNULL(stock.quantity, 0) as quantity, pl.`description_short`, pl.`available_now`, pl.`available_later`, pl.`link_rewrite`, pl.`name`, image_shop.`id_image` id_image, il.`legend`, m.`name` manufacturer_name ,( SELECT SUM(weight) FROM prstshp_search_word sw LEFT JOIN prstshp_search_index si ON sw.id_word = si.id_word WHERE sw.id_lang = 1 AND sw.id_shop = 1 AND si.id_product = p.id_product AND (sw.word LIKE '%moet%') ) position, DATEDIFF( p.`date_add`, DATE_SUB( "2020-08-27 00:00:00", INTERVAL 150 DAY ) ) > 0 new, product_attribute_shop.minimal_quantity AS product_attribute_minimal_quantity, IFNULL(product_attribute_shop.`id_product_attribute`,0) id_product_attribute FROM prstshp_product p INNER JOIN prstshp_product_shop product_shop ON (product_shop.id_product = p.id_product AND product_shop.id_shop = 1) INNER JOIN `prstshp_product_lang` pl ON ( p.`id_product` = pl.`id_product` AND pl.`id_lang` = 1 AND pl.id_shop = 1 ) LEFT JOIN `prstshp_product_attribute_shop` product_attribute_shop FORCE INDEX (id_product) ON (p.`id_product` = product_attribute_shop.`id_product` AND product_attribute_shop.`default_on` = 1 AND product_attribute_shop.id_shop=1) LEFT JOIN prstshp_stock_available stock ON (stock.id_product = `p`.id_product AND stock.id_product_attribute = 0 AND stock.id_shop = 1 AND stock.id_shop_group = 0 ) LEFT JOIN `prstshp_manufacturer` m FORCE INDEX (PRIMARY) ON m.`id_manufacturer` = p.`id_manufacturer` LEFT JOIN `prstshp_image_shop` image_shop FORCE INDEX (id_product) ON (image_shop.`id_product` = p.`id_product` AND image_shop.cover=1 AND image_shop.id_shop=1) LEFT JOIN `prstshp_image_lang` il ON (image_shop.`id_image` = il.`id_image` AND il.`id_lang` = 1) WHERE p.`id_product` IN (3718,4214,5271,5313,5585,5586,5587) GROUP BY product_shop.id_product ORDER BY position desc LIMIT 0,24</pre>
at line 769 in file classes/db/Db.php

 

764. if ($webservice_call && $errno) {

765. $dbg = debug_backtrace();

766. WebserviceRequest::getInstance()->setError(500, '

 ' . $this->getMsgError() . '. From ' . (isset($dbg[3]['class']) ? $dbg[3]['class'] : '') . '->' . $dbg[3]['function'] . '() Query was : ' . $sql, 97);


767. } elseif (_PS_DEBUG_SQL_ && $errno && !defined('PS_INSTALLATION_IN_PROGRESS')) {

768. if ($sql) {

769. throw new PrestaShopDatabaseException($this->getMsgError() . '<br /><br /><pre>' . $sql . '</pre>');

770. }

771.

772. throw new PrestaShopDatabaseException($this->getMsgError());

773. }

774. }

 

DbCore->displayError - [line 385 - classes/db/Db.php] - [1 Arguments]

DbCore->query - [line 613 - classes/db/Db.php] - [1 Arguments]

DbCore->executeS - [line 374 - classes/Search.php] - [3 Arguments]

SearchCore::find - [line 85 - src/Adapter/Search/SearchProductSearchProvider.php] - [9 Arguments]

PrestaShop\PrestaShop\Adapter\Search\SearchProductSearchProvider->runQuery - [line 308 - classes/controller/ProductListingFrontController.php] - [2 Arguments]

ProductListingFrontControllerCore->getProductSearchVariables - [line 580 - classes/controller/ProductListingFrontController.php]

ProductListingFrontControllerCore->doProductSearch - [line 82 - controllers/front/listing/SearchController.php] - [2 Arguments]

SearchControllerCore->initContent - [line 292 - classes/controller/Controller.php]

ControllerCore->run - [line 515 - classes/Dispatcher.php]

DispatcherCore->dispatch - [line 28 - index.php]

 

Can anybody help me?? 🙄

thanks in advace

Antakarana

Antakarana

Hi!!!

I have a similar problem ona a PS 1.7.6.7 shop

search bar doesnt work... actualy it only shows manufacturer results, but it doesnt show any product results.

When activating debug mode it shows this error code when I perform any search:

 

 

[PrestaShopDatabaseException]

Key 'id_product' doesn't exist in table 'product_attribute_shop'<br /><br /><pre>SELECT p.*, product_shop.*, stock.out_of_stock, IFNULL(stock.quantity, 0) as quantity, pl.`description_short`, pl.`available_now`, pl.`available_later`, pl.`link_rewrite`, pl.`name`, image_shop.`id_image` id_image, il.`legend`, m.`name` manufacturer_name ,( SELECT SUM(weight) FROM prstshp_search_word sw LEFT JOIN prstshp_search_index si ON sw.id_word = si.id_word WHERE sw.id_lang = 1 AND sw.id_shop = 1 AND si.id_product = p.id_product AND (sw.word LIKE '%moet%') ) position, DATEDIFF( p.`date_add`, DATE_SUB( "2020-08-27 00:00:00", INTERVAL 150 DAY ) ) > 0 new, product_attribute_shop.minimal_quantity AS product_attribute_minimal_quantity, IFNULL(product_attribute_shop.`id_product_attribute`,0) id_product_attribute FROM prstshp_product p INNER JOIN prstshp_product_shop product_shop ON (product_shop.id_product = p.id_product AND product_shop.id_shop = 1) INNER JOIN `prstshp_product_lang` pl ON ( p.`id_product` = pl.`id_product` AND pl.`id_lang` = 1 AND pl.id_shop = 1 ) LEFT JOIN `prstshp_product_attribute_shop` product_attribute_shop FORCE INDEX (id_product) ON (p.`id_product` = product_attribute_shop.`id_product` AND product_attribute_shop.`default_on` = 1 AND product_attribute_shop.id_shop=1) LEFT JOIN prstshp_stock_available stock ON (stock.id_product = `p`.id_product AND stock.id_product_attribute = 0 AND stock.id_shop = 1 AND stock.id_shop_group = 0 ) LEFT JOIN `prstshp_manufacturer` m FORCE INDEX (PRIMARY) ON m.`id_manufacturer` = p.`id_manufacturer` LEFT JOIN `prstshp_image_shop` image_shop FORCE INDEX (id_product) ON (image_shop.`id_product` = p.`id_product` AND image_shop.cover=1 AND image_shop.id_shop=1) LEFT JOIN `prstshp_image_lang` il ON (image_shop.`id_image` = il.`id_image` AND il.`id_lang` = 1) WHERE p.`id_product` IN (3718,4214,5271,5313,5585,5586,5587) GROUP BY product_shop.id_product ORDER BY position desc LIMIT 0,24</pre>
at line 769 in file classes/db/Db.php

764. if ($webservice_call && $errno) { 765. $dbg = debug_backtrace(); 766. WebserviceRequest::getInstance()->setError(500, '

 ' . $this->getMsgError() . '. From ' . (isset($dbg[3]['class']) ? $dbg[3]['class'] : '') . '->' . $dbg[3]['function'] . '() Query was : ' . $sql, 97); 767. } elseif (_PS_DEBUG_SQL_ && $errno && !defined('PS_INSTALLATION_IN_PROGRESS')) { 768. if ($sql) { 769. throw new PrestaShopDatabaseException($this->getMsgError() . '<br /><br /><pre>' . $sql . '</pre>'); 770. } 771. 772. throw new PrestaShopDatabaseException($this->getMsgError()); 773. } 774. }


DbCore->displayError - [line 385 - classes/db/Db.php] - [1 Arguments]

DbCore->query - [line 613 - classes/db/Db.php] - [1 Arguments]

DbCore->executeS - [line 374 - classes/Search.php] - [3 Arguments]

SearchCore::find - [line 85 - src/Adapter/Search/SearchProductSearchProvider.php] - [9 Arguments]

PrestaShop\PrestaShop\Adapter\Search\SearchProductSearchProvider->runQuery - [line 308 - classes/controller/ProductListingFrontController.php] - [2 Arguments]

ProductListingFrontControllerCore->getProductSearchVariables - [line 580 - classes/controller/ProductListingFrontController.php]

ProductListingFrontControllerCore->doProductSearch - [line 82 - controllers/front/listing/SearchController.php] - [2 Arguments]

SearchControllerCore->initContent - [line 292 - classes/controller/Controller.php]

ControllerCore->run - [line 515 - classes/Dispatcher.php]

DispatcherCore->dispatch - [line 28 - index.php]

 

Can anybody help me?? 🙄

thanks in advace

×
×
  • Create New...