Loading...

Database error: Table './icgiyimm_db/cscart_product_popularity' is marked as crashed and should be repaired (145)
Invalid query: SELECT SQL_CALC_FOUND_ROWS products.product_id, products.company_id, companies.company as company_name, descr1.product as product, products.tracking, products.feature_comparison, products.zero_price_action, products.product_type, products.tax_ids, products.weight, GROUP_CONCAT(IF(products_categories.link_type = 'M', CONCAT(products_categories.category_id, 'M'), products_categories.category_id)) as category_ids, min_qty, max_qty, products.qty_step, products.list_qty_count, products.is_edp, avail_since, buy_in_advance, products.options_type, products.exceptions_type, companies.company as company_name, products.product_code, products.amount, MIN(prices.price) as price, products.status, products.list_price, descr1.short_description, IF(descr1.short_description = '', descr1.full_description, '') as full_description, products_categories.position, cscart_seo_names.name as seo_name, IF(products.age_verification = 'Y', 'Y', IF(cscart_categories.age_verification = 'Y', 'Y', cscart_categories.parent_age_verification)) as age_verification, IF(products.age_limit > cscart_categories.age_limit, IF(products.age_limit > cscart_categories.parent_age_limit, products.age_limit, cscart_categories.parent_age_limit), IF(cscart_categories.age_limit > cscart_categories.parent_age_limit, cscart_categories.age_limit, cscart_categories.parent_age_limit)) as age_limit, popularity.total as popularity FROM cscart_products as products LEFT JOIN cscart_companies companies ON companies.company_id = products.company_id LEFT JOIN cscart_product_descriptions as descr1 ON descr1.product_id = products.product_id AND descr1.lang_code = 'EN' LEFT JOIN cscart_product_prices as prices ON prices.product_id = products.product_id AND prices.lower_limit = 1 LEFT JOIN cscart_product_prices as prices_2 ON prices.product_id = prices_2.product_id AND prices_2.lower_limit = 1 AND prices_2.price < prices.price AND prices_2.usergroup_id IN (0, 0, 1) INNER JOIN cscart_products_categories as products_categories ON products_categories.product_id = products.product_id INNER JOIN cscart_categories ON cscart_categories.category_id = products_categories.category_id AND (cscart_categories.usergroup_ids = '' OR FIND_IN_SET(0, cscart_categories.usergroup_ids) OR FIND_IN_SET(1, cscart_categories.usergroup_ids)) AND (products.usergroup_ids = '' OR FIND_IN_SET(0, products.usergroup_ids) OR FIND_IN_SET(1, products.usergroup_ids)) AND cscart_categories.status IN ('A', 'H') AND products.status IN ('A') LEFT JOIN cscart_seo_names ON cscart_seo_names.object_id = products.product_id AND cscart_seo_names.type = 'p' AND cscart_seo_names.dispatch = '' AND cscart_seo_names.lang_code = 'EN' LEFT JOIN cscart_product_sales ON cscart_product_sales.product_id = products.product_id AND cscart_product_sales.category_id = products_categories.category_id LEFT JOIN cscart_product_popularity as popularity ON popularity.product_id = products.product_id WHERE 1 AND products.company_id = 0 AND cscart_categories.category_id IN (75) AND popularity.total >= 1 AND prices.usergroup_id IN (0, 0, 1) AND prices_2.price IS NULL GROUP BY products.product_id ORDER BY popularity.total desc LIMIT 0, 66


Backtrace:

File:/home/icgiyimm/public_html/core/fn.database.php
Line:310
Function:db_error
File:/home/icgiyimm/public_html/core/fn.database.php
Line:37
Function:db_query
File:/home/icgiyimm/public_html/core/fn.catalog.php
Line:3432
Function:db_get_array
File:/home/icgiyimm/public_html/core/fn.cms.php
Line:728
Function:fn_get_products
File:/home/icgiyimm/public_html/core/templater_plugins/function.block.php
Line:232
Function:fn_get_block_items
File:/home/icgiyimm/public_html/core/templater_plugins/function.block.php
Line:64
Function:smarty_function_block_output
File:/home/icgiyimm/public_html/core/templater_plugins/function.block.php
Line:32
Function:smarty_function_group_output
File:/home/icgiyimm/public_html/var/compiled/customer/%%72^72D^72DAF6E8%%main.tpl.php
Line:13
Function:smarty_function_block
File:/home/icgiyimm/public_html/core/class.templater.php
Line:88
Function:include
File:/home/icgiyimm/public_html/var/compiled/customer/%%45^45E^45E480CD%%index.tpl.php
Line:357
Function:_smarty_include
File:/home/icgiyimm/public_html/lib/templater/Smarty.class.php
Line:1265
Function:include
File:/home/icgiyimm/public_html/lib/templater/Smarty.class.php
Line:1108
Function:fetch
File:/home/icgiyimm/public_html/core/class.templater.php
Line:122
Function:display
File:/home/icgiyimm/public_html/core/fn.control.php
Line:505
Function:display
File:/home/icgiyimm/public_html/index.php
Line:31
Function:fn_dispatch