点击发货,就出现这样的数据,求解决

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

MySQL server error report:Array ( [0] => Array ( [message] => MySQL Query Error ) [1] => Array ( [sql] => SELECT DG.goods_id, DG.is_real, DG.product_id, SUM(DG.send_number) AS sums, IF(DG.product_id > 0, P.product_number, G.goods_number) AS storage, G.goods_name, DG.send_number FROM `msapple`.`ecs_delivery_goods` AS DG, `msapple`.`ecs_goods` AS G, `msapple`.`ecs_products` AS P WHERE DG.goods_id = G.goods_id AND DG.delivery_id = '5' AND DG.product_id = P.product_id GROUP BY DG.product_id ) [2] => Array ( [error] => Unknown column 'DG.product_id' in 'field list' ) [3] => Array ( [errno] => 1054 ) )

回答:
貌似是数据库缺少字段

DG.product_id

这个字段。有问题。不存在。

为了积分路过

本地测试了下 没报错

应该是你数据库问题 缺少该字段

数据库有问题

数据库设置的事

明显你服务器上和本地。数据库字段就不一样。