17,086
社区成员
发帖
与我相关
我的任务
分享
select weight.minecode minecode,
substr(weight.grosstime,0,10) qgrosstime,
c.custname custname,
v.vname vname,
pc.name custarea,
weight.zprice zprice,
weight.grossweight grossweight,
weight.tareweight tareweight,
weight.netweight netweight,
substr(weight.grosstime,0,10) grosstime
from
(select w.minecode minecode,
w.custno custno,
w.varno varno,w.grosstime grosstime,
s.custarea custarea,
nvl(w.netweight,0)*nvl(s.freightprice,0) zprice,
nvl(w.grossweight,0) grossweight,
nvl(w.tareweight,0) tareweight,
nvl(w.netweight,0) netweight
from sale_weight w, sale_notice s
where w.minecode = s.minecode(+)
and w.noticeno = s.noticeno(+)
and w.weightflag = '1'
and w.minecode = '7025' and w.grosstime>='2018-09-01 00:00:00' and w.grosstime<='2018-09-18 23:59:59')weight,
cust_custinfo c, pub_vardict v,pub_custarea pc
where weight.custno=c.custno(+)
and weight.varno=v.vcode(+)
and weight.custarea=pc.id(+)
order by substr(weight.grosstime,0,10),c.custname,v.vname,pc.name