update b set b.salemlpris=1604.51 / (case when isnull(b.qtyelse,0)>0 then b.qtyelse else b.qty end),
b.saleps=1604.51 / (case when isnull(b.qtyelse,0)>0 then b.qtyelse else b.qty end)/(1+b.taxrate*0.01)
,b.TaxMny=1604.51*(0.16)
from sa_Order a
inner join sa_Orderlist b on b.orderno=a.orderno
b.saleps=1604.51 / (case when isnull(b.qtyelse,0)>0 then b.qtyelse else b.qty end)/(1+b.taxrate*0.01)
,b.TaxMny=1604.51*(0.16)
from sa_Order a
inner join sa_Orderlist b on b.orderno=a.orderno
where a.orderno='YHDSO-201806200115' and b.autoid='38'
备注:未税单价、含税单价、含税总价