Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Pawlowski

Новичок
  
  • Content Count

    26
  • Joined

  • Last visited

Community Reputation

0 Обычный

About Pawlowski

  • Rank
    Пользователь

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Uncaught Exception: Error: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'ON (pd.product_id = p2s.product_id) WHERE pd.product_id ='42' AND p2s.store_i' at line 1<br />Error No: 1064<br />SELECT * FROM oc_product_description pd LEFT JOIN oc_product_to_store p2s ON (pd.product_id = p2s.product_id) WHERE pd.product_id ='42' AND p2s.store_id = '0' AND pd.language_id = '2' in D:\xampp\htdocs\opencart\system\library\db\mysqli.php:40 Stack trace: #0 D:\xampp\htdocs\opencart\system\library\db.php(4
  2. public function getAltName($product_id) { ; $query = $this->db->query("SELECT * FROM " . DB_PREFIX . "product_description pd LEFT JOIN " . DB_PREFIX . "product_to_store p2s ON (pd.alt_name = p2s.store_id) WHERE pd.product_id ='" . (int)$product_id. "' AND p2s.store_id = '" . (int)$this->config->get('config_store_id') . "' AND language_id = '" . (int)$this->config->get('config_language_id') . "'"); return $query->row['alt_name']; } Случайно написал... Вот сейчас у меня такой запрос. И вот такая ошибка Fatal error: Uncaught Exception: Error: You have a
  3. public function getAltName($product_id) { ; $query = $this->db->query("SELECT * FROM " . DB_PREFIX . "product_description pd LEFT JOIN " . DB_PREFIX . "product_to_store p2s ON (pd.product_id = p2s.store_id) WHERE pd.product_id ='" . (int)$product_id. "' AND p2s.store_id = '" . (int)$this->config->get('config_store_id') . "' AND language_id = '" . (int)$this->config->get('config_language_id') . "'"); return $query->row['alt_name']; } Тоже самое: Fatal error: Uncaught Exception: Error: You have an error in your SQL syntax; check t
  4. $query = $this->db->query("SELECT * FROM " . DB_PREFIX . "product_description pd LEFT JOIN " . DB_PREFIX . "product_to_store p2s ON (pd.alt_name = p2s.store_id) WHERE pd.product_id ='" . (int)$product_id. "'AND p2s.store_id = '" . (int)$this->config->get('config_store_id') . "'AND language_id = '" . (int)$this->config->get('config_language_id') . "'"); Fatal error: Uncaught Exception: Error: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'ON (pd.alt_name = p2s.store_id) WHERE pd.pr
  5. public function getAltName($product_id) { ; $query = $this->db->query("SELECT * FROM " . DB_PREFIX . "product_description LEFT JOIN " . DB_PREFIX . "product_to_store ON (pd.alt_name = p2s.store_id) WHERE product_id ='" . (int)$product_id. "'AND store_id = '" . (int)$this->config->get('config_store_id') . "'AND language_id = '" . (int)$this->config->get('config_language_id') . "'"); return $query->row['alt_name']; } Fatal error: Uncaught Exception: Error: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version
  6. Т.е. когда я смогу объединить две таблицы , alt_name будет выводить значение?
  7. {{ text_alt_name }} {{ alt_name }} Первое выводит как - Альтернативное имя Второе пустое Хорошо, сейчас добавлю
  8. {{ text_alt_name }} {{ alt_name }} Первое выводит как - Альтернативное имя Второе пустое Хорошо, сейчас добавлю
  9. public function getAltName($product_id) { ; $query = $this->db->query("SELECT alt_name FROM " . DB_PREFIX . "product_description WHERE product_id ='" . (int)$product_id. "'AND store_id = '" . (int)$this->config->get('config_store_id') . "'AND language_id = '" . (int)$this->config->get('config_language_id') . "'"); return $query->row['alt_name']; }
  10. Cпасибо, теперь выводиться только одно значение. Но в нужное поле все равно не вписывается...
  11. Спасибо, сейчас гляну. Возможно ли то, если я подправляю это , то в поле "Альтернативное имя" будет выводиться данные с колонки или нет?
×
×
  • Create New...

Important Information

On our site, cookies are used and personal data is processed to improve the user interface. To find out what and what personal data we are processing, please go to the link. If you click "I agree," it means that you understand and accept all the conditions specified in this Privacy Notice.