日期:2014-05-16 浏览次数:20808 次
SELECT a.item_desc,a.targer_org_code,a.targer_sub_code,a.send_date, '调拨入库' ordertype ,a.txn_number,d.line_status
FROM tg_org_transfer a LEFT JOIN tg_record b ON a.txn_number=b.recordcode AND a.item_num=b.item_num
LEFT JOIN tg_barcode_history c ON a.txn_number=c.billcode AND a.item_num=c.item_num INNER JOIN tg_org_transfer_lines@BARCODE01_ERP01 d ON a.line_id=d.line_id
WHERE b.IDX IS NULL AND send_date>to_date('2013-3-6','yyyy-mm-dd') AND send_date<to_date('2013-3-8','yyyy-mm-dd')