Error
[Exception, 0]
Exception: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'site_master_template.products_id' in 'where clause' in /home/xumbaprinting/public_html/lib/Classes/Models/RMasterModel.php:89
Stack trace:
#0 /home/xumbaprinting/public_html/model/TemplateMaster.php(650): RMasterModel->exec_query()
#1 /home/xumbaprinting/public_html/templates/include/twig_functions.php(1702): TemplateMaster->get_template_details_filter()
#2 /home/xumbaprinting/public_html/product_designs.php(114): getTemplateRecords()
#3 {main}
@line 702 in file /home/xumbaprinting/public_html/lib/Classes/Models/RMasterModel.php
Debug Backtrace
#1 RMasterModel.php:91 -- RMasterModel->displayException()
#2 TemplateMaster.php:650 -- RMasterModel->exec_query()
#3 twig_functions.php:1702 -- TemplateMaster->get_template_details_filter()
#4 product_designs.php:114 -- getTemplateRecords()
Last Query :
SELECT SQL_CALC_FOUND_ROWS count(DISTINCT site_master_template.template_id) as site_total, 0 as 'master_total',site_master_template.template_language_ids,GROUP_CONCAT(site_master_template.color,'') as color,GROUP_CONCAT(DISTINCT site_master_template.orientation,'') as orientation FROM site_master_template
LEFT JOIN site_master_template_description ON site_master_template_description.template_id = site_master_template.template_id AND ( site_master_template_description.site_language_id =1 OR site_master_template_description.site_language_id IS NULL)
RIGHT JOIN products ON products.products_id=site_master_template.products_id LEFT JOIN product_category ON product_category.category_id=products.category_id WHERE site_master_template.status = '1' AND (site_master_template.products_id = 235 OR site_master_template.duplicate_product_id LIKE '%,235-%') AND ((site_master_template.user_type_id IN ('0', '1') AND (site_master_template.user_ids = ''))) AND ( site_master_template.studiodata !='') AND (site_master_template.size_id IN ('1050', '1067', '1068', '1069', '1070', '1059', '1063', '1065', '1056', '1064', '1057', '1060', '1061', '1071', '1066', '1058', '1062', '1072', '1052', '1051', '1053', '1054', '1055') OR site_master_template.duplicate_product_id LIKE '%-1050,%' OR site_master_template.duplicate_product_id LIKE '%-1067,%' OR site_master_template.duplicate_product_id LIKE '%-1068,%' OR site_master_template.duplicate_product_id LIKE '%-1069,%' OR site_master_template.duplicate_product_id LIKE '%-1070,%' OR site_master_template.duplicate_product_id LIKE '%-1059,%' OR site_master_template.duplicate_product_id LIKE '%-1063,%' OR site_master_template.duplicate_product_id LIKE '%-1065,%' OR site_master_template.duplicate_product_id LIKE '%-1056,%' OR site_master_template.duplicate_product_id LIKE '%-1064,%' OR site_master_template.duplicate_product_id LIKE '%-1057,%' OR site_master_template.duplicate_product_id LIKE '%-1060,%' OR site_master_template.duplicate_product_id LIKE '%-1061,%' OR site_master_template.duplicate_product_id LIKE '%-1071,%' OR site_master_template.duplicate_product_id LIKE '%-1066,%' OR site_master_template.duplicate_product_id LIKE '%-1058,%' OR site_master_template.duplicate_product_id LIKE '%-1062,%' OR site_master_template.duplicate_product_id LIKE '%-1072,%' OR site_master_template.duplicate_product_id LIKE '%-1052,%' OR site_master_template.duplicate_product_id LIKE '%-1051,%' OR site_master_template.duplicate_product_id LIKE '%-1053,%' OR site_master_template.duplicate_product_id LIKE '%-1054,%' OR site_master_template.duplicate_product_id LIKE '%-1055,%') AND (site_master_template.template_language_ids = '0' OR FIND_IN_SET('1',site_master_template.template_language_ids)) Prepared Statement :
SELECT SQL_CALC_FOUND_ROWS count(DISTINCT site_master_template.template_id) as site_total, 0 as 'master_total',site_master_template.template_language_ids,GROUP_CONCAT(site_master_template.color,'') as color,GROUP_CONCAT(DISTINCT site_master_template.orientation,'') as orientation FROM site_master_template
LEFT JOIN site_master_template_description ON site_master_template_description.template_id = site_master_template.template_id AND ( site_master_template_description.site_language_id =:smtd_site_language_id OR site_master_template_description.site_language_id IS NULL)
RIGHT JOIN products ON products.products_id=site_master_template.products_id LEFT JOIN product_category ON product_category.category_id=products.category_id WHERE site_master_template.status = :site_master_template_status AND (site_master_template.products_id = :smt_products_id OR site_master_template.duplicate_product_id LIKE :smt_dup_product_id) AND ((site_master_template.user_type_id IN (:input_34, :input_35) AND (site_master_template.user_ids = :user_ids_131339961620241121042929))) AND ( site_master_template.studiodata !='') AND (site_master_template.size_id IN (:input_36, :input_37, :input_38, :input_39, :input_40, :input_41, :input_42, :input_43, :input_44, :input_45, :input_46, :input_47, :input_48, :input_49, :input_50, :input_51, :input_52, :input_53, :input_54, :input_55, :input_56, :input_57, :input_58) OR site_master_template.duplicate_product_id LIKE :smt_product_id1 OR site_master_template.duplicate_product_id LIKE :smt_product_id2 OR site_master_template.duplicate_product_id LIKE :smt_product_id3 OR site_master_template.duplicate_product_id LIKE :smt_product_id4 OR site_master_template.duplicate_product_id LIKE :smt_product_id5 OR site_master_template.duplicate_product_id LIKE :smt_product_id6 OR site_master_template.duplicate_product_id LIKE :smt_product_id7 OR site_master_template.duplicate_product_id LIKE :smt_product_id8 OR site_master_template.duplicate_product_id LIKE :smt_product_id9 OR site_master_template.duplicate_product_id LIKE :smt_product_id10 OR site_master_template.duplicate_product_id LIKE :smt_product_id11 OR site_master_template.duplicate_product_id LIKE :smt_product_id12 OR site_master_template.duplicate_product_id LIKE :smt_product_id13 OR site_master_template.duplicate_product_id LIKE :smt_product_id14 OR site_master_template.duplicate_product_id LIKE :smt_product_id15 OR site_master_template.duplicate_product_id LIKE :smt_product_id16 OR site_master_template.duplicate_product_id LIKE :smt_product_id17 OR site_master_template.duplicate_product_id LIKE :smt_product_id18 OR site_master_template.duplicate_product_id LIKE :smt_product_id19 OR site_master_template.duplicate_product_id LIKE :smt_product_id20 OR site_master_template.duplicate_product_id LIKE :smt_product_id21 OR site_master_template.duplicate_product_id LIKE :smt_product_id22 OR site_master_template.duplicate_product_id LIKE :smt_product_id23) AND (site_master_template.template_language_ids = '0' OR FIND_IN_SET(:site_master_template_template_language_ids,site_master_template.template_language_ids)) Params: Array
(
[:smtd_site_language_id] => 1
[:site_master_template_status] => 1
[:smt_products_id] => 235
[:smt_dup_product_id] => %,235-%
[:user_ids_131339961620241121042929] =>
[:smt_product_id1] => %-1050,%
[:smt_product_id2] => %-1067,%
[:smt_product_id3] => %-1068,%
[:smt_product_id4] => %-1069,%
[:smt_product_id5] => %-1070,%
[:smt_product_id6] => %-1059,%
[:smt_product_id7] => %-1063,%
[:smt_product_id8] => %-1065,%
[:smt_product_id9] => %-1056,%
[:smt_product_id10] => %-1064,%
[:smt_product_id11] => %-1057,%
[:smt_product_id12] => %-1060,%
[:smt_product_id13] => %-1061,%
[:smt_product_id14] => %-1071,%
[:smt_product_id15] => %-1066,%
[:smt_product_id16] => %-1058,%
[:smt_product_id17] => %-1062,%
[:smt_product_id18] => %-1072,%
[:smt_product_id19] => %-1052,%
[:smt_product_id20] => %-1051,%
[:smt_product_id21] => %-1053,%
[:smt_product_id22] => %-1054,%
[:smt_product_id23] => %-1055,%
[:site_master_template_template_language_ids] => 1
[:input_34] => 0
[:input_35] => 1
[:input_36] => 1050
[:input_37] => 1067
[:input_38] => 1068
[:input_39] => 1069
[:input_40] => 1070
[:input_41] => 1059
[:input_42] => 1063
[:input_43] => 1065
[:input_44] => 1056
[:input_45] => 1064
[:input_46] => 1057
[:input_47] => 1060
[:input_48] => 1061
[:input_49] => 1071
[:input_50] => 1066
[:input_51] => 1058
[:input_52] => 1062
[:input_53] => 1072
[:input_54] => 1052
[:input_55] => 1051
[:input_56] => 1053
[:input_57] => 1054
[:input_58] => 1055
)
Show Less...
#0 /home/xumbaprinting/public_html/model/TemplateMaster.php(648): RMasterModel->setCustomQuery('SELECT SQL_CALC_FOUND_ROWS count(DISTINCT site_master_template.template_id) as site_total, 0 as 'master_total',site_master_template.template_language_ids,GROUP_CONCAT(site_master_template.color,'') as color,GROUP_CONCAT(DISTINCT site_master_template.orientation,'') as orientation FROM site_master_template
LEFT JOIN site_master_template_description ON site_master_template_description.template_id = site_master_template.template_id AND ( site_master_template_description.site_language_id =:smtd_site_language_id OR site_master_template_description.site_language_id IS NULL)
RIGHT JOIN products ON products.products_id=site_master_template.products_id LEFT JOIN product_category ON product_category.category_id=products.category_id WHERE site_master_template.status = :site_master_template_status AND (site_master_template.products_id = :smt_products_id OR site_master_template.duplicate_product_id LIKE :smt_dup_product_id) AND ((site_master_template.user_type_id IN @user_type_id_131339961620241121042929 AND (site_master_template.user_ids = :user_ids_131339961620241121042929))) AND ( site_master_template.studiodata !='') AND (site_master_template.size_id IN @product_sizes1 OR site_master_template.duplicate_product_id LIKE :smt_product_id1 OR site_master_template.duplicate_product_id LIKE :smt_product_id2 OR site_master_template.duplicate_product_id LIKE :smt_product_id3 OR site_master_template.duplicate_product_id LIKE :smt_product_id4 OR site_master_template.duplicate_product_id LIKE :smt_product_id5 OR site_master_template.duplicate_product_id LIKE :smt_product_id6 OR site_master_template.duplicate_product_id LIKE :smt_product_id7 OR site_master_template.duplicate_product_id LIKE :smt_product_id8 OR site_master_template.duplicate_product_id LIKE :smt_product_id9 OR site_master_template.duplicate_product_id LIKE :smt_product_id10 OR site_master_template.duplicate_product_id LIKE :smt_product_id11 OR site_master_template.duplicate_product_id LIKE :smt_product_id12 OR site_master_template.duplicate_product_id LIKE :smt_product_id13 OR site_master_template.duplicate_product_id LIKE :smt_product_id14 OR site_master_template.duplicate_product_id LIKE :smt_product_id15 OR site_master_template.duplicate_product_id LIKE :smt_product_id16 OR site_master_template.duplicate_product_id LIKE :smt_product_id17 OR site_master_template.duplicate_product_id LIKE :smt_product_id18 OR site_master_template.duplicate_product_id LIKE :smt_product_id19 OR site_master_template.duplicate_product_id LIKE :smt_product_id20 OR site_master_template.duplicate_product_id LIKE :smt_product_id21 OR site_master_template.duplicate_product_id LIKE :smt_product_id22 OR site_master_template.duplicate_product_id LIKE :smt_product_id23) AND (site_master_template.template_language_ids = '0' OR FIND_IN_SET(:site_master_template_template_language_ids,site_master_template.template_language_ids))', Array, Array)647: }
648: $this->setCustomQuery($Query, $this->getCustomParams(), $this->getCustomTypes());
649: //echo $this->getSQL($this->getFullQuery()); exit;
#1 /home/xumbaprinting/public_html/model/TemplateMaster.php(648): RMasterModel->getCustomTypes()647: }
648: $this->setCustomQuery($Query, $this->getCustomParams(), $this->getCustomTypes());
649: //echo $this->getSQL($this->getFullQuery()); exit;
#2 /home/xumbaprinting/public_html/model/TemplateMaster.php(648): RMasterModel->getCustomParams()647: }
648: $this->setCustomQuery($Query, $this->getCustomParams(), $this->getCustomTypes());
649: //echo $this->getSQL($this->getFullQuery()); exit;
#3 /home/xumbaprinting/public_html/model/TemplateMaster.php(586): RMasterModel->setCustomParams(Array, Array)585: $sLangJoin = " AND ( site_master_template_description.site_language_id =:smtd_site_language_id OR site_master_template_description.site_language_id IS NULL)";
586: $this->setCustomParams(array(':smtd_site_language_id' => $language_id), array(':smtd_site_language_id' => 'int'));
587: }
#4 /home/xumbaprinting/public_html/templates/include/twig_functions.php(1699): RMasterModel->setCustomParams(Array, Array)1698: $MWhereCondN .= " OR FIND_IN_SET(:master_template_template_language_ids,master_template.template_language_ids)" ;
1699: $objTemplateMaster->setCustomParams(array(":site_master_template_template_language_ids"=>SITE_LANGUAGE_ID,":master_template_template_language_ids"=>SITE_LANGUAGE_ID), array(":site_master_template_template_language_ids"=>'string',":master_template_template_language_ids"=>'string'));
1700: $WhereCondN .= ")";
#5 /home/xumbaprinting/public_html/templates/include/twig_functions.php(1688): RMasterModel->setCustomParams(Array, Array)1687: $MWhereCondN .= " OR master_template.duplicate_product_id LIKE :mt_product_id$i";
1688: $objTemplateMaster->setCustomParams(array(":smt_product_id$i"=>"%-$size_data,%",":mt_product_id$i"=>"%-$size_data,%"),array(":smt_product_id$i"=>"string",":mt_product_id$i"=>"string"));
1689: $i++;
#6 /home/xumbaprinting/public_html/templates/include/twig_functions.php(1683): RMasterModel->setCustomParams(Array, Array)1682: $MWhereCondN .= " AND (master_template.size_id IN @product_sizes2";
1683: $objTemplateMaster->setCustomParams(array("@product_sizes1"=>$product_sizes, "@product_sizes2"=>$product_sizes), array("@product_sizes1"=>"int","@product_sizes2"=>"int"));
1684: $i = 1;
#7 /home/xumbaprinting/public_html/templates/include/twig_functions.php(1663): RMasterModel->setCustomParams(Array, Array)1662: $WhereCondN .= $storeAccess[0];
1663: $objTemplateMaster->setCustomParams($storeAccess[1], $storeAccess[2]);
1664: $WhereCondN .= " AND ( site_master_template.studiodata !='')" ;
#8 /home/xumbaprinting/public_html/templates/include/twig_functions.php(1650): RMasterModel->setCustomParams(Array, Array)1649: $MWhereCondN .= " AND ( master_template.products_id = :mt_products_id OR master_template.duplicate_product_id LIKE :mt_dup_product_id)";
1650: $objTemplateMaster->setCustomParams(array(':mt_products_id'=>$pid, ':mt_dup_product_id'=>"%,$pid-%"), array(':mt_products_id'=>'int', ':mt_dup_product_id'=>'string'));
1651: }
#9 /home/xumbaprinting/public_html/templates/include/twig_functions.php(1648): RMasterModel->setCustomParams(Array, Array)1647: $WhereCondN .= " AND (site_master_template.products_id = :smt_products_id OR site_master_template.duplicate_product_id LIKE :smt_dup_product_id)";
1648: $objTemplateMaster->setCustomParams(array(':smt_products_id'=>$pid, ':smt_dup_product_id'=>"%,$pid-%"), array(':smt_products_id'=>'int', ':smt_dup_product_id'=>'string'));
1649: $MWhereCondN .= " AND ( master_template.products_id = :mt_products_id OR master_template.duplicate_product_id LIKE :mt_dup_product_id)";
#10 /home/xumbaprinting/public_html/templates/include/twig_functions.php(1636): RMasterModel->setCustomParams(Array, Array)1635: $MWhereCondN = " master_template.status = :master_template_status";
1636: $objTemplateMaster->setCustomParams(array(':master_template_status'=>'1'), array(':master_template_status'=>'string'));
1637:
#11 /home/xumbaprinting/public_html/templates/include/twig_functions.php(1634): RMasterModel->setCustomParams(Array, Array)1633: $WhereCondN = " site_master_template.status = :site_master_template_status" ;
1634: $objTemplateMaster->setCustomParams(array(':site_master_template_status'=>'1'), array(':site_master_template_status'=>'string'));
1635: $MWhereCondN = " master_template.status = :master_template_status";