Jump to content

error page


mahmoud.labid

Recommended Posts

If you look at the sourcecode of ps_facetedsearch.php around line 970 you see:

$values = array();
foreach ($currency_list as $currency) {
	$values[] = '('.(int) $id_product.',
		'.(int) $currency['id_currency'].',
		'.$id_shop.',
		'.(int) $min_price[$currency['id_currency']].',
		'.(int) Tools::ps_round($max_price[$currency['id_currency']] * (100 + $max_tax_rate) / 100, 0).')';
}

Db::getInstance()->execute('
	INSERT INTO `'._DB_PREFIX_.'layered_price_index` (id_product, id_currency, id_shop, price_min, price_max)
	VALUES '.implode(',', $values).'
	ON DUPLICATE KEY UPDATE id_product = id_product # avoid duplicate keys');

It goes wrong with the line "VALUES '.implode(',', $values).'" in the query. That means that $values is empty. 

$values is created in the foreach loop above it. That suggests that something was wrong with $currency_list. Are there no currencies defined?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...