Database_Exception [ 1064 ]: 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 ') AND `brand_id` IN () ORDER BY `available` DESC, `name`, RAND() LIMIT 30' at line 1 [ SELECT `product`.* FROM `products` AS `product` WHERE `id` IN ('7438', '7439', '7440', '7441', '7442', '7443', '7444', '7445', '7446', '7447', '7448', '7449', '7450', '7451', '7452', '7453', '7454', '7456', '7457', '7458', '7459', '7460', '7461', '7463', '7464', '7465', '7466', '7467', '7468', '7469', '7470', '7455', '7462') AND `transfered` = 0 AND `show` = 1 AND `deleted` = 0 AND `brand_id` IN () AND `brand_id` IN () ORDER BY `available` DESC, `name`, RAND() LIMIT 30 ]

MODPATH/database/classes/kohana/database/mysql.php [ 194 ]

189 			{
190 				// This benchmark is worthless
191 				Profiler::delete($benchmark);
192 			}
193 
194 			throw new Database_Exception(':error [ :query ]',
195 				array(':error' => mysql_error($this->_connection), ':query' => $sql),
196 				mysql_errno($this->_connection));
197 		}
198 
199 		if (isset($benchmark))
  1. MODPATH/database/classes/kohana/database/query.php [ 245 ] » Kohana_Database_MySQL->query(arguments)

  2. MODPATH/orm/classes/kohana/orm.php [ 963 ] » Kohana_Database_Query->execute(arguments)

  3. MODPATH/orm/classes/kohana/orm.php [ 922 ] » Kohana_ORM->_load_result(arguments)

  4. APPPATH/classes/controller/frontend/catalog.php [ 190 ] » Kohana_ORM->find_all()

  5. {PHP internal call} » Controller_Frontend_Catalog->action_catalog()

  6. SYSPATH/classes/kohana/request/client/internal.php [ 118 ] » ReflectionMethod->invoke(arguments)

  7. SYSPATH/classes/kohana/request/client.php [ 64 ] » Kohana_Request_Client_Internal->execute_request(arguments)

  8. SYSPATH/classes/kohana/request.php [ 1138 ] » Kohana_Request_Client->execute(arguments)

  9. DOCROOT/index.php [ 109 ] » Kohana_Request->execute()

Environment