Sie sind auf Seite 1von 144

Sales Order Listing

Sales Organization

to

Dist Channel

to

Division

to

Plant

to

Sales Office

to

Sales Order

to

Order Type

to

Sold to Party

to

Owner

to

Material

to

Document date

to

Material Type

to

Material Group

to

Material Group 1

to

Material Group 2

to

Material Group 3

to

Size

to

Gol

to

Collection

to

Reason for Rejection

to

Released SO

[U]

Outstanding SO

[M]

[A]
[B]
[C]
[D]
[E]
[F]
[G]
[H]
[I]
[J]
[K]
[L]
[M]
[N]
[O]
[P]
[Q]
[R]

[S]
[T]

[A]

Sales Organization

VBAK-VKORG

[B]

Dist Channel

VBAK-VTWEG

[C]

Division

VBAK-SPART

[D]

Plant

VBAP-WERKS

[E]

Sales office

VBAK-VKBUR

[F]

Sales Order

VBAK-VBELN

[G]

Order Type

VBAK-AUART

[H]

Sold to Party

VBAK-KUNNR

[I]

Owner

VBPA-KUNNR where VBPA-VBELN = [E] and VBPA-PARVW

[J]

Material

VBAP-MATNR

[K]

Document Date

VBAK-AUDAT

[L]

Mat Type

MARA-MTART where MARA-MATNR = VBAP-MATNR

[M]

Mat Group

VBAP-MATKL

[N]

Mat Group 1

VBAP-MVGR1

[O]

Mat Group 2

VBAP-MVVGR2

[P]

Mat Group 3

VBAP-MVGR3

[Q]

Size

VBAP-MVGR4

[R]

Gol

VBAP-MVGR5

[S]

Collection

MARA-NORMT where MARA-MATNR = VBAP-MATNR

[T]

Reason for Rejection

VBAP-ABGRU

[U]

Released

jika di-tick, select VBUK-VBELN where VBUK-LSSTK = ' '

[M]

Salesman

VBPA-KUNNR where VBPA-VBELN= [E] and VBPA-PARVW

Promo code
Project code

VBPA-KUNNR where VBPA-VBELN= [E] and VBPA-PARVW


VBPA-KUNNR where VBPA-VBELN= [E] and VBPA-PARVW

Cust Grp

select VBKD-KDGRP where VBKD-VBELN = [1]

VBELN = [E] and VBPA-PARVW = '1A', (jika tidak ada cari VBPA-PARVW = '1B' or '1C' or '1D'

-MATNR = VBAP-MATNR

ARA-MATNR = VBAP-MATNR

BELN where VBUK-LSSTK = ' '

VBELN= [E] and VBPA-PARVW = 'Z1'

VBELN= [E] and VBPA-PARVW = 'Z6' or 'Z7', or 'Z8' or 'Z9'


VBELN= [E] and VBPA-PARVW = 'Z5'

ere VBKD-VBELN = [1]

Sales Order Listing

PT XYZ

Sales Order

SO Item

Created Date
Doc Date

1a

Owner Owner Name 1

3-1

SJC1506/0042

10

6/5/2015

ASAYA JAYA BERSAMA SEJAHTERA, P

SJC1506/0003
SJC1506/0004
SJC1506/0004
Grand Total
Super Grand Total

10
10
10

6/6/2015
6/7/2015
6/8/2015

SARANA, CV / TB. BAJA


SARANA, CV / TB. BAJA
SARANA, CV / TB. BAJA

Ket : Data bisa dikeluarkan listing dan outstanding

1 Sales Order
1a SO Item
2 Created date
3a GET OWNER ADDRESS NO
3-1 Owner
3 Owner Name 1
3-2 Owner Name 2
4 Material
5 Material Desc

select
select
select
select
select
select
select
select
select

VBAK-VBELN where VBAK-VBTYP = 'C' or 'L'


VBAP-POSNR where VBAP-VBELN = [1]
VBAK-AUDAT where VBAK-VBELN = [1]
VBPA-ADRNR where VBPA-VBELN = [1] and VBPA-PARVW = '1A', (jika tidak ada
VBPA-KUNNR where VBPA-VBELN = [1] and VBPA-PARVW = '1A', (jika tidak ada
ADRC-NAME1 where ADRC-ADDRNUMBER = [3a]
ADRC-NAME2 where ADRC-ADDRNUMBER = [3a]
VBAP-MATNR where VBAP-VBELN = [1] and VBAP-POSNR = [1a]
VBAP-ARKTX where VBAP-VBELN = [1] and VBAP-POSNR = [1a]

6a GET GOL HARGA ID


6 Gol
7a GET KW ID
7b GET QTY
7 GRD 1
8 GRD 2
9 GRD 3
10a GET ODO NO & ITEM
10b GET PGI STATUS
10 Delivered

11 Balance
12a GET ORDER SRKI
12 Prod Qty SRKI

13 Prod Sched SRKI


14a GET ORDER RCI
14 Prod Qty RCI

select VBAP-MVGR5 where VBAP-VBELN = [1] and VBAP-POSNR = [1a]


select TVM5-BEZEI where TVM5-MVGR5 = [6a]
select VBAP-KONDM where VBAP-VBELN = [1] and VBRP-POSNR = [1a]
select VBAP-KWMENG where VBAP-VBELN = [1] and VBRP-POSNR = [1a]
if [7a] = '01' or '04' print [7b], else blank
if [7a] = '02' or '05' print [7b], else blank
if [7a] = '03' print [7b], else blank
select LIPS-VBELN, LIPS-POSNR where LIPS-VGBEL = [1] and LIPS-VGPOS = [1a]
select VBUP-WBSTA where VBUP-VBELN = [10a] and VBUP-POSNR = [10a]
if [10b] = 'C'
select sum LIPS-FKIMG where LIPS-VBELN = [10a] and LIPS-POSNR = [10a]
else print 0
[7b] - [10]

select CAUFV-AUFNR where CAUFV-WERKS = 'B101' and CAUFV-PLNBEZ = [4] and ta


if MSEG-MBLNR ne 0 where MSEG-AUFNR = [12a]
select CAUFV-GAMNG where CAUFV-WERKS = 'B101' and CAUFV-PLNBEZ = [4] and ta
else ambil order kedua dst
select CAUFV-GSTRP where CAUFV-AUFNR = [12]

15 Prod Sched RCI

select CAUFV-AUFNR where CAUFV-WERKS = 'B102' and CAUFV-PLNBEZ = [4] and ta


if MSEG-MBLNR ne 0 where MSEG-AUFNR = [14a]
select CAUFV-GAMNG where CAUFV-WERKS = 'B102' and CAUFV-PLNBEZ = [4] and ta
else ambil order kedua dst
CAUFV-GSTRP dari Order no [14]

16 Physical Stock

if VBAK-VKBUR = 'D150' and VBAP-WERKS = 'D101'

select MARD-LABST where MARD-MATNR = [4] and MARD-WERKS


else if VBAK-VKBUR = 'D151' and VBAP-WERKS = 'D101'
select MARD-LABST where MARD-MATNR = [4] and MARD-WERKS
else if VBAK-VKBUR = 'D154' and VBAP-WERKS = 'D101'
select MARD-LABST where MARD-MATNR = [4] and MARD-WERKS
else if VBAK-VKBUR = 'D155' and VBAP-WERKS = 'D101'
select MARD-LABST where MARD-MATNR = [4] and MARD-WERKS
else if VBAK-VKBUR = 'D156' and VBAP-WERKS = 'D101'
select MARD-LABST where MARD-MATNR = [4] and MARD-WERKS
else if VBAK-VKBUR = 'D152' and VBAP-WERKS = 'D102'
select MARD-LABST where MARD-MATNR = [4] and MARD-WERKS
else if VBAK-VKBUR = 'D153' and VBAP-WERKS = 'D103'
select MARD-LABST where MARD-MATNR = [4] and MARD-WERKS
else if VBAP-WERKS = 'D104','D105','D106'
select MARD-LABST where MARD-MATNR = [4] and MARD-WERKS
else if VBAP-WERKS = 'B101','B102'
select MARD-LABST where MARD-MATNR = [4] and MARD-WERKS

17 Free Stock

18a GET SHIP TO ADDRESS NO


18 Delivery Address 1
18-1 Delivery Address 2
18-2 Delivery Address 3
18-3 Deliv City
18-4a GET TRANS ZONE
18-4 Deliv Trans Zone
18-5a GET REGION

SEE FM AVAILABILITY_CHECK

select
select
select
select
select
select
select
select

= [20] and MAR

= [20] and MAR

= [20] and MAR

= [20] and MAR

= [20] and MAR

= [20] and MAR

= [20] and MAR

= [20] and MAR

= [20] and MAR

--> nyotek report ZRSD_OUTSTANDING_SO1

VBPA-ADRNR where VBPA-VBELN = [1] and VBPA-PARVW = 'SH' or 'WE'


ADRC-STREET where ADRC-ADDRNUMBER = [18a]
ADRC-STR_SUPPL3 where ADRC-ADDRNUMBER = [18a]
ADRC-LOCATION where ADRC-ADDRNUMBER = [18a]
ADRC-CITY1 where ADRC-ADDRNUMBER = [18a]
ADRC-TRANSPZONE where ADRC-ADDRNUMBER = [18a]
TZONT-VTEXT where TZONT-ZONE1 = [18-4a] and TZONT-LAND1 = [18-6] and
ADRC-REGION where ADRC-ADDRNUMBER = [18a]

18-5 Deliv Region


18-7a GET DELIV REG STRUC GRP
18-7 Deliv Reg Structure Grp
18-6 Deliv Country
19 Ship Date
20 Plant
20-1 Plant Name
21a GET SIZE ID
21 Size
22a GET NET VALUE PER LINE
22b GET DOC CONDITION NO
22c GET COND HEADER LEVEL ITEM
22d GET SURCHARGE LEVEL ITEM
22 Net Price

23 Net Value

select
select
select
select
select
select

T005U-BEZEI where T005U-BLAND = [18-5a], T005U-LAND1 = [18-6], T005U-S


ADRC-REGIOGROUP where ADRC_ADDRNUMBER = [18a]
ADRREGGRPT-DESCRIPT where ADRREGGRPT-REGIOGROUP = [18-7a]
ADRC-COUNTRY where ADRC-ADDRNUMBER = [18a]
VBEP-EDATU where VBEP-VBELN = [1] and VBEP-POSNR = [1a]
VBAP-WERKS where VBAP-VBELN = [1] and VBAP-POSNR = [1a]

select VBAP-MVGR4 where VBAP-VBELN = [1] and VBAP-POSNR = [1a]


select TVM4-BEZEI where TVM4-MVGR4 = [21a]
select VBAP-NETWR where VBAP-VBELN = [1] and VBAP-POSNR = [1a]
select VBAK-KNUMV where VBAK-VBELN = [1]
select sum KONV-KWERT where KONV-KNUMV = [22b] and KONV-KPOSN = [1a] and K
select sum VBAP-KZWI3 where VBAP-VBELN = [1] and VBAP-POSNR = [1a]
if VBAK-VTWEG = '20'
--> ekspor
[23] / [7b]
else
--> selain ekspor
select VBAP-NETPR where VBAP-VBELN = [1] and VBAP-POSNR = [1a]
if VBAK-VTWEG = '20'
--> ekspor
[22a] - [22c] - [22d]
else
--> selain ekspor
select VBAP-NETWR where VBAP-VBELN = [1] and VBAP-POSNR = [1a]

24 Currency

select VBAK-WAERK where VBAK-VBELN = [1]

25 PO Cust

using FM READ_TEXT (ID = Z040, LANGUAGE = EN, NAME = [1], OBJECT = VBBK)
jika text kosong
select VBKD-BSTKD where VBKD-VBELN = [1]

26 Customer
27a GET ADDRESS NO
27 Customer Name

select VBAK-KUNNR where VBAK-VBELN = [1]


select VBPA-ADRNR where VBPA-VBELN = [1] and VBPA-PARVW = 'SP' or 'AG'
select ADRC-NAME 1 where ADRC-ADDRNUMBER = [8b]

28a GET PROJECT CODE ADDR NO


28 Project Code

select VBPA-ADRNR where VBPA-VBELN = [1] and VBPA-PARVW = 'Z5'


select VBPA-KUNNR where VBPA-VBELN = [1] and VBPA-PARVW = 'Z5'

28-1 Project Code Desc 1


28-2 Project Code Desc 2
29a GET PROMO CODE ADDR NO
29 Promo Code 1
29-1 Promo Code 1 Desc 1
29-2 Promo Code 1 Desc 2
30a GET PROMO CODE ADDR NO
30 Promo Code 2
30-1 Promo Code 2 Desc 1
30-2 Promo Code 2 Desc 2
31a GET PROMO CODE ADDR NO
31 Promo Code 3
31-1 Promo Code 3 Desc 1
31-2 Promo Code 3 Desc 2
32a GET PROMO CODE ADDR NO
32 Promo Code 4
32-1 Promo Code 4 Desc 1
32-2 Promo Code 4 Desc 2
33a GET SALESMAN ID
33 Salesman
34 Quotation
35 SO Type
36 Status SO
37 S. District
38 SPB No
39 No ODO
40 Std Price
41 Diff Std Price

select
select
select
select
select
select
select
select
select
select
select
select
select
select
select
select
select
select

ADRC-NAME1 where ADRC-ADDRNUMBER = [28a]


ADRC-NAME2 where ADRC-ADDRNUMBER = [28a]
VBPA-ADRNR where VBPA-VBELN = [1] and VBPA-PARVW
VBPA-KUNNR where VBPA-VBELN = [1] and VBPA-PARVW
ADRC-NAME1 where ADRC-ADDRNUMBER = [29a]
ADRC-NAME2 where ADRC-ADDRNUMBER = [29a]
VBPA-ADRNR where VBPA-VBELN = [1] and VBPA-PARVW
VBPA-KUNNR where VBPA-VBELN = [1] and VBPA-PARVW
ADRC-NAME1 where ADRC-ADDRNUMBER = [30a]
ADRC-NAME2 where ADRC-ADDRNUMBER = [30a]
VBPA-ADRNR where VBPA-VBELN = [1] and VBPA-PARVW
VBPA-KUNNR where VBPA-VBELN = [1] and VBPA-PARVW
ADRC-NAME1 where ADRC-ADDRNUMBER = [31a]
ADRC-NAME2 where ADRC-ADDRNUMBER = [31a]
VBPA-ADRNR where VBPA-VBELN = [1] and VBPA-PARVW
VBPA-KUNNR where VBPA-VBELN = [1] and VBPA-PARVW
ADRC-NAME1 where ADRC-ADDRNUMBER = [38a]
ADRC-NAME2 where ADRC-ADDRNUMBER = [38a]

select
select
select
select

VBPA-PERNR where VBPA-PARVW = 'Z1'


PA0002-NACHN where PA0002-PERNR = [33a]
VBAK-VGBEL where VBAK-VBELN = [1] and VBAK-VGTYP = 'B'
VBAK-AUART where VBAK-VBELN = [1]

= 'Z6'
= 'Z6'

= 'Z7'
= 'Z7'

= 'Z8'
= 'Z8'

= 'Z9'
= 'Z9'

select VBKD-BZIRK where VBKD-VBELN = [1] and VBKD-POSNR = [1a]


select LIKP-LIFEX where LIKP-VBELN = [39]
select LIPS-VBELN where LIPS-VGBEL = [1] -->LIPS-VBELN bisa lebih dari satu
see ZFM_SD_GET_PRICE_DEALER
if VBAK-AUART = 'ZCB2', 'ZAB2', 'ZBB2' --> untuk print out di transaksi non regular
select KONV-KWERT where KONV-KNUMV = [42a] and KONV-KSCHL = 'ZP00' and KO
lalu dibagi Qty [7b]
lalu kurangi dengan PRICE DEALER [40]
else if VBAK-AUART = 'ZCB3'

select KONV-KWERT where KONV-KNUMV = [42a] and KONV-KSCHL = 'ZP03' and KO

lalu dibagi Qty [7b]


lalu kurangi dengan PRICE DEALER [40]

42a GET DOC CONDITION


42 Disc special prc

43 Collection
44 Net Weight
45 Sales Unit
46 Org Doc Retur

47 Created By
48a GET AGENT ADDRESS NO
48 Agent
48-1 Agent name1
48-2 Agent name2
49 Batch SO
50 Remarks Delivery
51 Sales Org
52 Dist Channel
53 Division
54 Release

select VBAK-KNUMV where VBAK-VBELN = [1]


if VBAK-AUART = 'ZCB2', 'ZAB2', 'ZBB2' --> untuk print out di transaksi non regular select sum KONV-KWERT where KONV-KSCHL = 'ZD22', 'ZD41', 'ZD42' and KONV-KP
lalu dibagi Qty [7b]
if VBAK-AUART = 'ZCB3' --> untuk print out di transaksi project
0

select MARA-NORMT where MARA-MATNR = [4]


select MARA-NTGEW where MARA-MATNR = [4]
select VBAP-VRKME where VBAP-VBELN = [1] and VBAP-POSNR = [1a]
if VBAK-AUART = 'ZCG1' or 'ZBG1' or 'ZAG1'
select VBFA-VBELV where VBFA-VBELN = [1] and VBFA-POSNV = [1a] and VBFA-VBTYP

select VBAK-ERNAM where VBAK-VBELN = [1]


select VBPA-ADRNR where VBPA-VBELN = [1] and VBPA-PARVW = 'Z3'
select VBPA-KUNNR where VBPA-VBELN = [1] and VBPA-PARVW = 'Z3'
select ADRC-NAME1 where ADRC-ADDRNUMBER = [48a]
select ADRC-NAME2 where ADRC-ADDRNUMBER = [48a]
select VBAP-CHARG where VBAP-VBELN = [1] and VBAP-POSNR = [1a]
using FM READ_TEXT (ID = Z004, LANGUAGE = EN, NAME = [1][1a], OBJECT = VBBP
select VBAK-VKORK where VBAK-VBELN = [1]
select VBAK-VTWEG where VBAK-VBELN = [1]
select VBAK-SPART where VBAK-VBELN = [1]
select VBUK-LSSTK = ' ' where VBUK-VBELN = [1]
check status profile
GET OBJECT NO
Select VBAK-OBJNR where VBAK-VBELN = [1]
FM
STATUS_READ
if INACT ne 'x' where STSMA = 'ZSD001' and S
data ditampilkan
else
data tidak ditampilkan

55 Outstanding
56 Remarks Charges

60 PGI Status
61 Reason for Rejection
62 Order Reason
63 Sales Office
63-1 Sales Office Desc
64 Salesman ID
65a GET MAT TYPE
65 Mat Type
66a GET MAT GROUP
66 Mat Group
67a GET MAT GRP 1
67 Mat Grp 1
68a GET MAT GRP 2
68 Mat Grp 2
69a GET MAT GRP 3
69 Mat Grp 3
70 Ship-To Telp No
71 Ship-To HP No
72a GET CUST GRP
72 Cust Group

select VBUP-LFSTA ne 'C' where VBUP-VBELN = [1] and VBUP-POSNR = [1a]


using FM READ_TEXT (ID = Z017, LANGUAGE = EN, NAME = [1], OBJECT = VBBK)
using FM READ_TEXT (ID = Z020, LANGUAGE = EN, NAME = [1], OBJECT = VBBK)
select VBAP-VKAUS where VBAP-VBELN = [1] and VBAP-POSNR = [1a]
jika SO non regular ada quotationnya atau SO Project ada usage nya
if [35] = 'ZAB2' or 'ZBB2' or 'ZCB2' and [34] ne 0 print 'SP'
else if [35] = 'ZAB2' or 'ZBB2' or 'ZCB2' and [58] ne 0 print ' SP'
else if [35] = 'ZCB3' and [58] ne 0 print 'SP'
else dikosongkan saja
[10b]
select VBAP-ABGRU where VBAP-VBELN = [1] and VBAP-POSNR = [1a]
select VBAK-AUGRU where VBAK-VBELN = [1]
select VBAK-VKBUR where VBAK-VBELN = [1]
select TVKBT-BEZEI where TVKBT-VKBUR = [63] and TVKBT-SPRAS = 'EN'
[33a]
select MARA-MTART where MARA-MATNR = [4]
select T134T-MTBEZ where T134T-MTART = [65a] and T134T-SPRAS = 'EN'
select VBAP-MATKL where VBAP-VBELN = [1] and VBAP-POSNR [1a]
select T023T-WGBEZ where T023T-MATKL = [66a] and T023T-SPRAS = 'EN'
select VBAP-MVGR1 where VBAP-VBELN = [1] and VBAP-POSNR = [1a]
select TVM1T-BEZEI where TVM1T-MVGR1 = [67a] and TVM1T-SPRAS = 'EN'
select VBAP-MVGR2 where VBAP-VBELN = [1] and VBAP-POSNR = [1a]
select TVM2T-BEZEI where TVM2T-MVGR1 = [68a] and TVM2T-SPRAS = 'EN'
select VBAP-MVGR3 where VBAP-VBELN = [1] and VBAP-POSNR = [1a]
select TVM3T-BEZEI where TVM3T-MVGR3 = [69a] and TVM3T-SPRAS = 'EN'
select ADR2-TEL_NUMBER where ADR2-ADDRNUMBER =[18a] and ADR2-R3_USER =
select ADR2-TEL_NUMBER where ADR2-ADDRNUMBER =[18a] and ADR2-R3_USER =
select VBKD-KDGRP where VBKD-VBELN = [1]
select T151T-KTEXT where T151T-KDGRP = [72a] and T151T-SPRAS = 'EN'

73a GET REGION SOLD TO


73 Sold To Region

select ADRC-REGION where ADRC-ADDRNUMBER = [27a]


select T005U-BEZEI where T005U-BLAND = [73a], T005U-LAND1 = [75], T005U-SPRA

57 Debit Memo
58 usage
59 Special Price

74a GET REG STRUC SOLD TO


74 Sold To Reg Structure Grp
74-1a GET SOLD TO TRANS ZONE
74-1 Sold to Trans Zone
74-2 Sold to City
75 Sold To Country
76 PGI Date

select
select
select
select
select
select
select

ADRC-REGIOGROUP where ADRC_ADDRNUMBER = [27a]


ADRREGGRPT-DESCRIPT where ADRREGGRPT-REGIOGROUP = [74a]
ADRC-TRANSPZONE where ADRC-ADDRNUMBER = [27a]
TZONT-VTEXT where TZONT-ZONE1 = [74-1a] and TZONT-LAND1 = [75] and T
ADRC-CITY1 where ADRC-ADDRNUMBER = [27a]
ADRC-COUNTRY where ADRC-ADDRNUMBER = [27a]
LIKP-WADAT_IST where LIKP-VBELN = [39]

77a GET PRICE GRP


77 PRICE GROUP

select VBKD-KONDA where VBKD-VBELN = [1]


select T188T-VTEXT where T188T-KONDA = [77a] and T188T-SPRAS = 'EN'

78a GET REGION OWNER


78 Owner Region
79a GET REG STRUC Owner
79 Owner Reg Structure Grp
80 Owner Country
81a GET OWNER TRANS ZONE
81 Owner Trans Zone
82 Owner City
SPB Qty
Project Group

select
select
select
select
select
select
select
select

ADRC-REGION where ADRC-ADDRNUMBER = [3a]


T005U-BEZEI where T005U-BLAND = [78a], T005U-LAND1 = [80], T005U-SPRA
ADRC-REGIOGROUP where ADRC_ADDRNUMBER = [3a]
ADRREGGRPT-DESCRIPT where ADRREGGRPT-REGIOGROUP = [79a]
ADRC-COUNTRY where ADRC-ADDRNUMBER = [3a]
ADRC-TRANSPZONE where ADRC-ADDRNUMBER = [3a]
TZONT-VTEXT where TZONT-ZONE1 = [81a] and TZONT-LAND1 = [80] and TZ
ADRC-CITY1 where ADRC-ADDRNUMBER = [3a]

Owner Name 2

Material

Material Name
Material Description

Gol
Price category

3-2

RSAMA SEJAHTERA, PGT602134CR

dAugusta Black Rectified REGULER

TB. BAJA
TB. BAJA
TB. BAJA

dOttawa Antico Rectified ULTIMA


dBalsa Wengue Rectified STANDARD
dOttawa Walnut Rectified ULTIMA

GT915508R
GT612205R
GT915511R

0.0125
80

80

20 23 40 41 42

--> belum muncul

GRD 3

1000
26
153
68
1492
1492

W = '1A', (jika tidak ada cari VBPA-PARVW = '1B' or '1C' or '1D'


= '1A', (jika tidak ada cari VBPA-PARVW = '1B' or '1C' or '1D'

R = [1a]
= [1a]

GRD 1 GRD 2

972
972

R = [1a]

R = [1a]
NR = [1a]

PS-VGPOS = [1a]
SNR = [10a]

SNR = [10a]

V-PLNBEZ = [4] and tanggal generate report antara CAUFV-GSTRP and CAUFV-GLTRP

FV-PLNBEZ = [4] and tanggal generate report antara CAUFV-GSTRP and CAUFV-GLTRP

V-PLNBEZ = [4] and tanggal generate report antara CAUFV-GSTRP and CAUFV-GLTRP

QTY

FV-PLNBEZ = [4] and tanggal generate report antara CAUFV-GSTRP and CAUFV-GLTRP

sched

jika HOR mangga dua

WERKS = [20] and MARD-LGORT = 'H001'


HOR fatmawati

WERKS = [20] and MARD-LGORT = 'H002'


HOR Medan

WERKS = [20] and MARD-LGORT = 'H006'


HOR Kelapa Gading

WERKS = [20] and MARD-LGORT = 'H007'


HOR Bandung

WERKS = [20] and MARD-LGORT = 'H008'


HOR Surabaya

WERKS = [20] and MARD-LGORT = 'H003'


HOR Semarang

WERKS = [20] and MARD-LGORT = 'H005'


RC

WERKS = [20] and MARD-LGORT = 'RFM1'

WERKS = [20] and MARD-LGORT = 'IFM1', 'IFM2','IFM3','IFM4','IFM5'

_OUTSTANDING_SO1

W = 'SH' or 'WE'

NT-LAND1 = [18-6] and TZONT-SPRAS = 'EN'

Plant Factory

ND1 = [18-6], T005U-SPRAS = 'EN'

OUP = [18-7a]

= [1a]
R = [1a]

R = [1a]

R = [1a]
223000050

NV-KPOSN = [1a] and KONV-KSCHL = ' ZD37, ZD38 '


OSNR = [1a]

NR = [1a]

R = [1a]

1], OBJECT = VBBK)

W = 'SP' or 'AG'

W = 'Z5'
= 'Z5'

AGT602170R

W = 'Z6'
= 'Z6'

W = 'Z7'
= 'Z7'

W = 'Z8'
= 'Z8'

W = 'Z9'
= 'Z9'

= 'B'
--> Di Hide

R = [1a]
// belum keluar
lebih dari satu

transaksi non regular


KSCHL = 'ZP00' and KONV-KPOSN = [18a]

KSCHL = 'ZP03' and KONV-KPOSN = [18a]

transaksi non regular --> ambil disount yg diinput manual


1', 'ZD42' and KONV-KPOSN = [1a]

--> ambil nilai weight mat master


R = [1a]

= [1a] and VBFA-VBTYP_V = 'J'

W = 'Z3'
= 'Z3'

R = [1a]
1][1a], OBJECT = VBBP)

re VBAK-VBELN = [1]

SMA = 'ZSD001' and STAT = 'E0002'

POSNR = [1a]
1], OBJECT = VBBK)
1], OBJECT = VBBK)
= [1a]
ge nya

R = [1a]

RAS = 'EN'

PRAS = 'EN'
[1a]
SPRAS = 'EN'
R = [1a]
SPRAS = 'EN'
R = [1a]
SPRAS = 'EN'
R = [1a]
SPRAS = 'EN'
and ADR2-R3_USER = '1'
and ADR2-R3_USER = '3'

PRAS = 'EN'

D1 = [75], T005U-SPRAS = 'EN'

--> Di Hide/hilangkan

OUP = [74a]

NT-LAND1 = [75] and TZONT-SPRAS = 'EN'

PRAS = 'EN'

D1 = [80], T005U-SPRAS = 'EN'

OUP = [79a]

-LAND1 = [80] and TZONT-SPRAS = 'EN'

Delivered

Balance

10

11
500
300

12
500
200
153
68

251
251

tgl mulai prod


Prod Qty SRKI Prod Sched SRKI

13
5000 20.01.2016

Prod Qty RCI

Prod Sched RCI

14

15

// ambil order yg belum di GI


CAUFV-IGMNG eq 0 --> artinya belum di GI ataua sudah di GI tapi cancel
select AUFK-OBJNR where AUFK-AUFNR = CAUFV-AUFNR
IF JEST-INACT = ' ' where JEST-STAT = I0045 or JEST-I0046 and JEST-OBJNR = AUFK-OBJNR
jika ada yg kondisi di atas jangan diambil
jika qty di proses order sama dgn 0
cari plan order dengan tanggal sesuai system date
ambil qty nya

if CAUFV-GAMNG = 0
select PLAF-PSTTR where PLAF-PLNUM = [12]

ambil dari Sloc mana aja?

if CAUFV-GAMNG eq 0

ambil dari sloc mana aja?


Physical Stock

16

Free Stock

Delivery Address 1

Delivery Address 2

17

18

18-1

NG eq 0
select PLAF-PLNUM where PLAF-PLWRK = 'B101' and tanggal generate report ada di antara PLAF-PSTTR dan PLAF-PEDTR
select PLAF-GSMNG where PLAF-PLNUM = [12b]

Delivery Address 3

Delivery City

Deliv Trans Zone

Delivery Region

Reg Structure Grp

18-2

18-3

18-4

18-5

18-7

PEDTR

Delivery Country

Ship Date

Plant

Size

Price
Net Price

Amount
Net Value

Currency

Cust PO No
PO Cust

18-6

19

20

21

22

23

24

25

Sold to Party

26
02JTKA0011
02JTKS0039
02JTKS0039
02JTKS0039

Sold to Party Name 1 Sold to Party Name 2 Project Code Project Code Name 1

27

27-1

28

28-1

Project Code Name 2 Promo Code 1Promo 1 Name 1 Promo 1 Name 2 Promo code Promo
2
2 Name
Promo
1
2 NamePromo
2
Code 3

28-2

29

29-1

29-2

30

30-1

30-2

31

Promo 3 Name
Promo
1
3 NamePromo
2
CodePromo
4
4 Name
Promo
1
4 Name 2Salesman Quotation SO Type

31-1

31-2

32

32-1

32-2

33

34

35

Status SOS. District

36

37

Ext Deliv No
SPB

ODO No
No ODO

Std Price

Diff Std Price

Disc special prc

38

39

40

41

42

Collection Net Weight

43

44

UoM

45

Org Doc Retur Created By

46

47

Agent

48

Agent name Agent name2 Batch SO Remarks Delivery Sales Org Dist Channel

48-1

48-2

49

50

51

52

Div

53

Release Outstanding Remarks Charges


Debit memo No
Usage

54

55

56

57

58

Special PricePGI Status


Reason for Rejection
Order Reason

59

60

61

62

Sales Office

63

Salesman ID GET MAT Mat Type GET MAT Mat GroupGET MAT Mat Grp 1GET MAT Mat Grp 2GET MAT Mat Grp 3

64

65a

65

66a

66

67a

67

68a

68

69a

69

Ship-To TeShip-To H GET CUSTCust GrouGET REGI Sold To R GET REG Sold To ReGET SOLDSold to TrSold to CiSold To C

70

71

72a

72

73a

73

74a

74

74-1a

74-1

74-2

75

PGI Date GET PRICEPRICE GR GET REGI Owner ReGET REG Owner Reg
Owner Cou
GET OWNE
Owner TraOwner City

76

77a

77

78a

78

79a

79

80

81a

81

82

FM_AVAILIBILITY_CHECK
Input
table
Field

P_ATPCSX
MATNR
WERKS
LGORT

Ouput

PRREG
CHMOD
BDTER
IDXATP
RESMD
CHKFLG

table
Field

Total Free stock

P_ATPCC
ATPM1

ATPM1 - Total qty yang belum dikirim selain HOR - Total qty yang belum confirm

Desc
Material Number
Plant
Sloc

Checking Rule ATP


ATP: Check mode
Tanggal
Server ATP
ATP Server: Mode for Results of Check
ATP Server: Flag - check requirement (yes/no)

al qty yang belum dikirim selain HOR - Total qty yang belum confirmed d HOR

[4]
[20]
if VBAK-VKBUR = 'D150' and VBAP-WERKS = 'D101'
LGORT = 'H001'
else if VBAK-VKBUR = 'D151' and VBAP-WERKS = 'D101'
LGORT = 'H002'
else if VBAK-VKBUR = 'D154' and VBAP-WERKS = 'D101'
LGORT = 'H006'
else if VBAK-VKBUR = 'D155' and VBAP-WERKS = 'D101'
LGORT = 'H007'
else if VBAK-VKBUR = 'D156' and VBAP-WERKS = 'D101'
LGORT = 'H008'
else if VBAK-VKBUR = 'D152' and VBAP-WERKS = 'D102'
LGORT = 'H003'
else if VBAK-VKBUR = 'D153' and VBAP-WERKS = 'D103'
LGORT = 'H005'
else if VBAP-WERKS = 'D104','D105','D106'
LGORT = 'RFM1'
else if VBAP-WERKS = 'B101','B102'
LGORT = 'IFM1', 'IFM2','IFM3','IFM4','IFM5'

B
EXP
sys-date
1
X
X

belum confirmed d HOR

Plant yang di select di SO


HOR Mangga Dua

SO Outstanding
1 SO selain SO HOR
2 SO yg item cat bukan

HOR Fatmawati
HOR Medan
HOR Kelapa Gading

3 Item SO yg belum dib

HOR Bandung
4a
HOR Surabaya
HOR Semarang

4b
4c
4d

RC

5 Total qty yang belum d


Plant Factory

6 SO HOR yang belum c

6a
6b

7 Total qty yang belum c

O Outstanding
O selain SO HOR
select VBAK-VBELN where VBAK-VBTYP = 'C' and VBAK-AUART ne 'ZCB6'
O yg item cat bukan ZB03, ZB04, ZB06
select VBAP-KWMENG VBAP-PSTYV ne 'ZB03' or 'ZB04' or 'ZB06' and VBAP-VBELN = [1]

em SO yg belum dibuat ODO (difilter dengan VBUP)


select VBUP-LFSTA where VBUP-VBELN = [1]
if [3] = 'A'
select VBAP-KWMENG where VBAP-MATNR = [SO listing no 4] and VBAP-PSTY
else if [3] = 'B'
select VBAP-KWMENG, VBAP-POSNR where VBAP-MATNR = [SO listing no 4] a
select LIPS-LFIMG where VBAP-MATNR = [SO listing no 4] and LIPS-VGBEL =[1
[4b] - [4c]

otal qty yang belum dikirim selain HOR


[4a] + [4d]

O HOR yang belum confirm


select VBAK-VBELN where VBAK-VBTYP = 'C' and VBAK-AUART = 'ZCB6'
order qty select VBEP-WMENG
confirmed select VBEP-BMENG

otal qty yang belum confirmed di HOR


[6a] - [6b]

ELN = [1]

blm terkirim sama sekali


no 4] and VBAP-PSTYV ne 'ZB03' or 'ZB04' or 'ZB06' and VBAP-VBELN = [1] ambil yg bukan reserve
terkirim partial
R = [SO listing no 4] and VBAP-PSTYV ne 'ZB03' or 'ZB04' or 'ZB06' and VBAP- ambil Qty di SO yang bukan res
4] and LIPS-VGBEL =[1] and LIPS-VGPOS = [4b] and LIPS-VGTYP = 'C'
ambil Qty delivery
qty yg belum terkirim

ambil
ambil
ambil
ambil

SO HOR
ietm SO HOR yg material
order qty nya
confirmed qty nya

sama sekali
kan reserve
SO yang bukan reserve

m terkirim

SO HOR yg materialnya dipilih di report

med qty nya

ZFM_SD_GET_PRICE_DEALER

Input
Table
Field

IW_PRICE_IN
PRSDT
VKORG
VTWEG
KONDA

MATNR
MTART
MATKL
RKE_MVGR1
RKE_MVGR2
ZZMVGR3
ZZMVGR4
ZZMVGR5
KONDM
VRKME
Output

Table

IW_PRICE_OUT

VBKD-PRSDT
VBAK-VKORG
VBAK-VTWEG
if VBAP-MVGR1 = '001'
pilih price group '02'
else if VBAP-MVGR1 = '002'
pilih price group '51'
VBAP-MATNR
MARA-MTART where MARA-MATNR = VBAP-MATNR
VBAP-MATKL
VBAP-MVGR1
VBAP-MVGR2
VBAP-MVGR3
VBAP-MVGR4
VBAP-MVGR5
VBAP-KONDM
VBAP-VRKME

87854099106

--> dibuatkan table yg bisa dimaintain user untuk mapping MVGR1 dengan Price Group

TNR = VBAP-MATNR

Mat grp 1
001
002
003
004
005
006

ZTSD_MAT_PRICE

Price Group
Desc
Ceramic
Granit
Mesin Tile Cut
Accessories Tile Cut

Slab
Std Item

TSD_MAT_PRICE

Price Group Desc


02
RM DL01
51
RG DL01

NO Sales order
Tgl So dibuat
Nama Owner customer
Kode material
Nama material
Material group 5

Material Pricing group


Qty yg dikirim
Sisa Qty order
Qty prod
Tgl prod fact SRKI
Qty prod
Tgl prod fact RCI
Stock Fisik bdsrkan plant yg diambil
Stock fisik - on order - reserved
Alamat Kirim
Tgl permintaan kirim
Plant yg kirim barang
Material Group 4
Harga Net Invoice
Qty x Harga net
Mata Uang
No PO Cust
Kode Cust
Nama Customer
Nama Project (dari project code)
Nama Project (dari project code)
Nama Project (dari project code)
Nama Project (dari project code)
Nama Project (dari project code)
Nama Sales
No quotation
SO Type
Status SO
District
No SPB
No ODO
Harga table price dealer std

Sales Order
Doc date
Owner Name 1
Material
Material Description
Gol
KW 1
KW 2
KW 3
Delivered
Balance
Prod Qty SRKI
Prod Sched SRKI
Prod Qty RCI
Prod Sched RCI
Physical Stock
Free Stock
Delivery Address
Ship Date
Plant
Size
Net Price
Net Value
Currency
PO Cust
Customer
Customer Name
Project Code
Promo Code 1
Promo Code 2
Promo Code 3
Promo Code 4
Salesman
Quotation
SO Type
Status SO
S. District
SPB
No ODO
Std Price

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40

Selisih harga dr table price dealer - harga


di SO special price
Diff Std Price
Discount special price
Disc special prc

41
42

Koleksi material (gabungan beberapa


material)
Berat material

43
44

Collection
Net Weight

Satuan
SPB asal u/transaksi retur
User yg entry

Sales Unit
Org Doc Retur
Created By

45
46
47

quantity per 3 bulan, min 2 order

baris ke 2, ke3 dst


selain no SO, no item & material, SPB qty, SPB No, DO no, PGI date, sisanya dibuat blan

jika DO blm di PGI, maka tidak perlu tambah line item

e, sisanya dibuat blank

Das könnte Ihnen auch gefallen