Здравствуйте при добавлении товара выскакивает ошибка, но товар добавляется как убрать ее Код: Error: 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 ')), isc.`search_data_1` = (SELECT CONCAT_WS(' ', )),isc.`search_data_3` = (SE' at line 11 Error No: 1064 UPDATE isearch_cache AS isc SET isc.`stores` = (SELECT GROUP_CONCAT(store_id SEPARATOR ',') FROM `product_to_store` WHERE product_id = isc.product_id GROUP BY product_id), isc.`name` = (SELECT CONCAT_WS(' ', (SELECT `name` FROM `product_description` WHERE product_id = isc.product_id AND language_id = '1'), (SELECT `name` FROM `product_description` WHERE product_id = isc.product_id AND language_id = '3'))), isc.`name_1` = (SELECT `name` FROM `product_description` WHERE product_id = isc.product_id AND language_id = '1'),isc.`name_3` = (SELECT `name` FROM `product_description` WHERE product_id = isc.product_id AND language_id = '3'), isc.`category_name_1` = (SELECT `name` FROM `category_description` WHERE category_id = isc.category_id AND language_id = '1'),isc.`category_name_3` = (SELECT `name` FROM `category_description` WHERE category_id = isc.category_id AND language_id = '3'), isc.`model` = (SELECT `model` FROM `product` WHERE product_id = isc.product_id), isc.`seo_url` = (SELECT GROUP_CONCAT(CONCAT_WS(':', ua.language_id, ua.keyword) ORDER BY ua.language_id ASC SEPARATOR '|') FROM `url_alias` AS ua WHERE ua.query = CONCAT('product_id=', isc.product_id) GROUP BY ua.query), isc.`description` = (SELECT CONCAT_WS(' ', (SELECT `description` FROM `product_description` WHERE product_id = isc.product_id AND language_id = '1'), (SELECT `description` FROM `product_description` WHERE product_id = isc.product_id AND language_id = '3'))), isc.`description_1` = (SELECT `description` FROM `product_description` WHERE product_id = isc.product_id AND language_id = '1'),isc.`description_3` = (SELECT `description` FROM `product_description` WHERE product_id = isc.product_id AND language_id = '3'), isc.`search_data` = (SELECT CONCAT_WS(' ', )), isc.`search_data_1` = (SELECT CONCAT_WS(' ', )),isc.`search_data_3` = (SELECT CONCAT_WS(' ', )), isc.`product_attributes` = (SELECT GROUP_CONCAT(CONCAT_WS(':', ad.language_id, ad.name, pa.text) SEPARATOR '|') FROM `product_attribute` AS pa LEFT JOIN `attribute_description` AS ad ON (pa.attribute_id = ad.attribute_id AND pa.language_id = ad.language_id) WHERE pa.product_id = isc.product_id GROUP BY pa.product_id), isc.`price` = (SELECT price FROM `product` WHERE product_id = isc.product_id), isc.`stock_status_id` = (SELECT stock_status_id FROM `product` WHERE product_id = isc.product_id), isc.`special` = (SELECT GROUP_CONCAT(CONCAT_WS(':', pspe.customer_group_id, pspe.priority, pspe.price, pspe.date_start, pspe.date_end) ORDER BY pspe.priority ASC SEPARATOR '|') FROM `product_special` AS pspe WHERE pspe.product_id = isc.product_id GROUP BY pspe.product_id), isc.`discount` = (SELECT GROUP_CONCAT(CONCAT_WS(':', pdis.customer_group_id, pdis.quantity, pdis.priority, pdis.price, pdis.date_start, pdis.date_end) ORDER BY pdis.priority ASC SEPARATOR '|') FROM `product_discount` AS pdis WHERE pdis.product_id = isc.product_id GROUP BY pdis.product_id), isc.`image` = (SELECT image FROM `product` WHERE product_id = isc.product_id), isc.`tax_class_id` = (SELECT tax_class_id FROM `product` WHERE product_id = isc.product_id), isc.`rating` = (SELECT AVG(rating) FROM `review` WHERE product_id = isc.product_id AND status = 1), isc.`date_available` = (SELECT date_available FROM `product` WHERE product_id = isc.product_id), isc.`reviews` = (SELECT COUNT(rating) FROM `review` WHERE product_id = isc.product_id AND status = 1), isc.`name_length_1` = LENGTH((SELECT `name` FROM `product_description` WHERE product_id = isc.product_id AND language_id = '1')),isc.`name_length_3` = LENGTH((SELECT `name` FROM `product_description` WHERE product_id = isc.product_id AND language_id = '3')), isc.`in_stock` = IF((SELECT `quantity` FROM `product` WHERE product_id = isc.product_id) > 0, 1, 0), isc.`sales_amount` = (SELECT COUNT(*) FROM `order_product` tempop LEFT JOIN `order` tempo ON (tempop.order_id = tempo.order_id) WHERE product_id = isc.product_id AND tempo.order_status_id = ''), isc.`orders_amount` = (SELECT COUNT(*) FROM `order_product` tempop LEFT JOIN `order` tempo ON (tempop.order_id = tempo.order_id) WHERE product_id = isc.product_id), isc.`viewed` = (SELECT `viewed` FROM `product` WHERE product_id = isc.product_id), isc.`status` = (SELECT `status` FROM `product` WHERE product_id = isc.product_id), isc.`quantity` = (SELECT `quantity` FROM `product` WHERE product_id = isc.product_id) WHERE isc.product_id='62' in file /home/a/public_html/system/library/db/mysqli.php on line 41
В теории: Заходим в каталог vqmod/xml и в файле path_product.xml исправляем строку 11: Было $q = $this->db->query("SELECT p2c.`category_id`, cd.name FROM " . DB_PREFIX . "`product_to_category` p2c LEFT join " . DB_PREFIX . "category_description cd ON cd.category_id = p2c.`category_id` WHERE product_id = '".$this->request->get['product_id']."' Стало: $q = $this->db->query("SELECT p2c.`category_id`, cd.name FROM `" . DB_PREFIX . "product_to_category` p2c LEFT join " . DB_PREFIX . "category_description cd ON cd.category_id = p2c.`category_id` WHERE product_id = '".$this->request->get['product_id']."' --- Добавлено, 18 янв 2017 --- _______________________________________ типа вместо oc_`product_to_category` должно быть `oc_product_to_category` --- Добавлено, 18 янв 2017 --- А вторая часть походу связана с модулем Isearch
Это тут не при чём, можно оба варианта. В ошибке же сказано, в каком она месте: PHP: (SELECT CONCAT_WS(' ', )) И тут сразу очевидно в чём причина: CONCAT_WS - это миниумм 3 параметра, а тут 1 и запятая (и дальше повторы такого кода). Смахивает на кривой занул.
у меня нет такого файла вообще ( vqmod/xml и в файле path_product.xml исправляем строку 11: Dotrox, тогда где копать дальше
Удалить модуль isearch - это его ошибки, судя по названию таблицы. Исправлять не имеет смысла, неизвестно, что там должно было быть. Дешевле будет купить не нуленный.