在退货单里 供应商欠款金额减去本退货单总金额 表达式怎么写?
- 提问者: mengranren
- 等级:普通会员
- 时间:2015-09-11 22:26
- 悬赏:0
- 解决时间:2015-09-21 22:26
回答 共 2 条
http://www.yt-pos.com/ask/question.php?id=3664
- 回答者:赢通技术3
- 等级:皇冠会员
- 时间:2015-09-12 11:26
批发销售单:
上次欠款:
dec(db_data2('SELECT SUM((a.sheet_amt-a.order_amt-a.paid_amt-a.free_amt)*a.pay_type) FROM dbo.t_cust_accout_flow a,dbo.t_pf_out_master b WHERE a.cust_no=b.cust_no AND b.sheet_no=? AND a.oper_date<b.oper_date',max(sheet_no)))
本单欠款:
string(dec(db_data2('select sheet_amt-order_amt-paid_amt-free_amt from t_cust_accout_flow where sheet_no=?',sheet_no)),'0.00')
批发退货单中加入上次欠款金额:
上次欠款:
db_data2('SELECT SUM((a.sheet_amt-a.order_amt-a.paid_amt-a.free_amt)*a.pay_type) FROM dbo.t_cust_accout_flow a,dbo.t_pf_return_master b WHERE a.cust_no=b.cust_no AND b.sheet_no=? AND a.oper_date<b.oper_date',max(sheet_no))
上次欠款:
dec(db_data2('SELECT SUM((a.sheet_amt-a.order_amt-a.paid_amt-a.free_amt)*a.pay_type) FROM dbo.t_cust_accout_flow a,dbo.t_pf_out_master b WHERE a.cust_no=b.cust_no AND b.sheet_no=? AND a.oper_date<b.oper_date',max(sheet_no)))
本单欠款:
string(dec(db_data2('select sheet_amt-order_amt-paid_amt-free_amt from t_cust_accout_flow where sheet_no=?',sheet_no)),'0.00')
批发退货单中加入上次欠款金额:
上次欠款:
db_data2('SELECT SUM((a.sheet_amt-a.order_amt-a.paid_amt-a.free_amt)*a.pay_type) FROM dbo.t_cust_accout_flow a,dbo.t_pf_return_master b WHERE a.cust_no=b.cust_no AND b.sheet_no=? AND a.oper_date<b.oper_date',max(sheet_no))
- 回答者:浅逝
- 等级:金牌会员
- 时间:2015-09-15 10:39
快到期问题