是这样的两查询语句,基本上是一样的,但是一个可以通过,另一个提示货币值超出范围。
*平均进库价格查询
SELECT Ckgljcksjb.spdm, Ckgljcksjb.spmc, SUM(Ckgljcksjb.jksl),;
SUM(Ckgljcksjb.jksl*Ckgljcksjb.jkdj)/SUM(Ckgljcksjb.jksl);
FROM ckglsj!ckgljcksjb;
WHERE LEFT(Ckgljcksjb.dh ,2)= "JK";
GROUP BY Ckgljcksjb.spdm;
ORDER BY Ckgljcksjb.spdm
----------------------------------------------------------------
*平均出库价格查询
SELECT Ckgljcksjb.spdm, Ckgljcksjb.spmc, SUM(Ckgljcksjb.Cksl),;
SUM(Ckgljcksjb.Cksl*Ckgljcksjb.Ckdj)/ SUM(Ckgljcksjb.Cksl);
FROM ckglsj!ckgljcksjb;
WHERE LEFT(Ckgljcksjb.dh ,2)= "CK";
GROUP BY Ckgljcksjb.spdm;
ORDER BY Ckgljcksjb.spdm
平均出库价格查询无法通过。是什么原因,请大侠们看看。