点击 提交订单 后出现乱码

2016-07-07 15:27 来源:www.chinab4c.com 作者:ecshop专家

MySQL server error report:Array ( [0] => Array ( [message] => MySQL Query Error ) [1] => Array ( [sql] => SELECT goods_id, SUM(goods_number) AS num, MAX(extension_code) AS extension_code, MAX(product_id) AS product_id FROM `a0122010659`.`ecs_order_goods` WHERE order_id = '5' AND is_real = 1 GROUP BY goods_id, product_id ) [2] => Array ( [error] => Can't group on 'product_id' ) [3] => Array ( [errno] => 1056 ) )

回答:
MySQL server error report:Array ( [0] => Array ( [message] => MySQL Query Error ) [1] => Array ( [sql] => SELECT goods_id, SUM(goods_number) AS num, MAX(extension_code) AS extension_code, MAX(product_id) AS product_id FROM `a0122010659`.`ecs_order_goods` WHERE order_id = '5' AND is_real = 1 GROUP BY goods_id, product_id ) [2] => Array ( [error] => Can't group on 'product_id' ) [3] => Array ( [errno] => 1056 ) )

你好,看下后台的起始页。
你的mysql版本是多少,这个一般是该sql mysql不支持

方便pm过来你的后台和ftp吗,我们看下

你好,我也是同样问题,这个要怎样解决

修改 函数
change_order_goods_storage 大概 2188行
把 MAX(product_id) AS product_id FROM " . $GLOBALS['ecs']->table('order_goods') .
修改为
product_id FROM " . $GLOBALS['ecs']->table('order_goods') .

既删除 MAX(product_id) AS即可,有2处哦