SELECT
-- 得到算出的结果
sum(cm_id_coun)FROM
(
SELECT
-- 多条不同数据求和
sum(de.DOL_ORDERQUANTITY * i.IM_WEIGHT
) AS cm_id_coun
FROM
do_deliveryorderline de
LEFT JOIN im_itemattributenew i ON de.im_id = i.IM_ID
WHERE
de.doh_id = '526757'
AND i.wh_code = 'EEUDCA'
) count_tb