The WMS warehouse management system implements the "sending and receiving daily report" data query function. SQL statement: Oracle [SQL] www.2cto.com SELECT AA. PRODUCT_CNAME, AA. PRODUCT_ID, AA. PRODUCT_CODE, AA. MODEL, AA. MASTER_UNIT, AA. OTHER_UNIT, AA. PACKAGE_RATIO, AA. CUSTOMER, SUM (week) AS QTY_OUT_TODAY, QTY_TODAY, SUM (week) AS week, SUM (QTY_OUT) AS QTY_OUT, SUM (QTY_IN) AS QTY_IN FROM (select customer, PRODUCT_CNAME, PRODUCT_ID, PRODUCT_CODE, MODEL, MASTER_UNIT, OTHER_UNIT, PACKAGE_RATIO, case when WMS_OUT_CONFIRM_DATE <= TO_DATE (TO_CHAR (SYSDATE, 'yyyy-MM-dd HH24: mi: ss '), 'yyyy-MM-dd HH24: mi: ss') AND WMS_OUT_CONFIRM_DATE> sysdate and BIZ_SOURCE = '2' THEN MASTER_UNIT_QTY ELSE 0 end as QTY_OUT_TODAY, case when CONFIRM_DATE <= TO_DATE (TO_CHAR (SYSDATE, 'yyyy-MM-dd HH24: mi: ss'), 'yyyy-MM-dd HH24: mi: ss ') AND CONFIRM_DATE> sysdate and BIZ_SOURCE = '0' THEN MASTER_UNIT_QTY ELSE 0 end as QTY_IN_TODAY, www.2cto.com (select sum (MASTER_UNIT_QTY) from wms_inventory where category = h. product_id) as qty_today, case when BIZ_SOURCE = '2' THEN MASTER_UNIT_QTY ELSE 0 end as QTY_OUT, case when BIZ_SOURCE = '0' THEN MASTER_UNIT_QTY ELSE 0 end as QTY_IN FROM limit H) aa group by aa. PRODUCT_CNAME, AA. PRODUCT_ID, AA. PRODUCT_CODE, AA. MODEL, AA. MASTER_UNIT, AA. OTHER_UNIT, AA. PACKAGE_RATIO, AA. CUSTOMER order by AA. CUSTOMER