1. 당월발생하느 업체는 농심.. . 당월 화주대불금 정산해라
1. 당월발생하느 업체는 농심.. . 당월 화주대불금 정산해라
Sandblaster
etching glass
1. 2단계 동만사는.. 업체가 직접 운송한다. .
1. 직송은 areadirect
2. 업직은 areadirect 구분자 Y
SELECT WHCD || ' ' || ' ' || SUBSTR(TMS.GETWHNAME_FN(WHCD),4,30) AS BRANCH,
custcd,
max(custnm),
sku,
max(skunm),
sum(einqty),
SUM(INQTY),
(SELECT NVL(SUM(OUTQTY),0) FROM prd_army.TB_OUT02 WHERE DELIVERYDATE LIKE :ARG_DATE||'%' AND STATUS = '9' AND SKU = TB_IN02.SKU
AND WHCD = TB_IN02.WHCD) AS OUTQTY,
SUM(INQTY)-(SELECT NVL(SUM(OUTQTY),0) FROM prd_army.TB_OUT02 WHERE DELIVERYDATE LIKE :ARG_DATE||'%' AND STATUS = '9' AND SKU = TB_IN02.SKU
AND WHCD = TB_IN02.WHCD) AS 차이
FROM prd_army.TB_IN02
WHERE DELIVERYDATE LIKE :ARG_DATE||'%'
AND EXISTS (SELECT WHCD, sku FROM prd_army.TB_OUT02 WHERE SKU = TB_IN02.SKU AND WHCD = TB_IN02.WHCD )
and custcd='615'
GROUP BY WHCD, custcd, sku
ORDER BY WHCD desc;
SELECT MAX(B.FRTROOPDESCR), MAX(B.TOTROOPDESCR), A.ORDERNO, A.SKU, MAX(A.SKUNM), SUM(A.OUTQTY) FROM PRD_ARMY.TB_OUT02 A, PRD_ARMY.TB_OUT01 B
WHERE A.CUSTCD = '615' AND A.STATUS = '9' AND A.DELIVERYDATE LIKE '200604%' AND A.ORDERNO = B.ORDERNO
GROUP BY A.ORDERNO, A.SKU
SELECT WHCD || ' ' || ' ' || SUBSTR(TMS.GETWHNAME_FN(WHCD),4,30) AS BRANCH,
custcd,
max(custnm),
sku,
max(skunm),
sum(einqty),
SUM(INQTY),
(SELECT NVL(SUM(OUTQTY),0) FROM prd_army.TB_OUT02 WHERE DELIVERYDATE LIKE :ARG_DATE||'%' AND STATUS = '9' AND SKU = TB_IN02.SKU
AND WHCD = TB_IN02.WHCD) AS OUTQTY
FROM prd_army.TB_IN02
WHERE DELIVERYDATE LIKE :ARG_DATE||'%'
AND EXISTS (SELECT WHCD, sku FROM prd_army.TB_in02 WHERE SKU = TB_IN02.SKU AND WHCD = TB_IN02.WHCD )
GROUP BY WHCD, custcd, sku
ORDER BY sku desc;
select B_YMD,B_CUST,B_CUST_NM,B_SKU,B_SKU_NM,B_UNIT,sum(b_ipgo),sum(b_banpum) from wh8.jaesan_b
where b_ymd like '200603'
and b_j_code in('3029900','3049900','3129900','3149900')
group by B_YMD,B_CUST,B_CUST_NM,B_SKU,B_SKU_NM,B_UNIT
SELECT PRT_COMPANY, MAX(PRT_YYMM), PRT_SA,
max(PRT_SA_NAME),
SUM(PRT_U_GUM), SUM(PRT_GUM) AS NAPUM_GUM,
SUM(PRT_WORK_GUM),
SUM(PRT_2_GUM),
SUM(PRT_SU) AS IPGO_BOX_SU
FROM TMS.TMS_REPORT_02
WHERE PRT_COMPANY IN ('U', '1')
AND PRT_YYMM = '200603' AND PRT_WH_CD <> '98' AND PRT_2_GUM <> 0
GROUP BY PRT_COMPANY, PRT_SA
ORDER BY PRT_SA;
SELECT ORDER_SA, MAX(ORDER_SA_NAME),SUM(ORDER_SU), SUM(ORDER_GUM3), SUM(ORDER_GUM4)
FROM TMS.TMS_ORDER
WHERE ORDER_J_DATE LIKE '200603%'
AND ORDER_WH_CD = 'WH1' --AND ORDER_SA NOT IN ('249','288','503','564','B32','C75','C76','629')
AND (ORDER_OK IN ('Y', 'Z') OR (ORDER_GB2 = '3' AND ORDER_OK = 'S') OR (ORDER_NO LIKE '%Y%' AND ORDER_OK = 'S')) AND ORDER_GUM3 <> 0
GROUP BY ORDER_SA
ORDER BY ORDER_SA