on 12-22-2008 2:16 PM
Hi experts,
If address numer is found in table t001w this is working fine.
user required custom address directly hardcode based plant and sorg which doen't contain record in table t001w.
I am not getting adrnr in table t001w , so I am writing hardcode but its not working , can you please tell me how to solve this issue.
This is ouput parameter &GV_ADDNR_VENDOR&
READ TABLE it_ekpo into wa_ekpo INDEX 1.
SELECT SINGLE * FROM t001w INTO ls_t001w
WHERE werks EQ wa_ekpo-werks.
if wa_ekpo-werks = '2000' and wa_ekpo-lgort = '5200'.
ls_t001w-NAME1 = 'Connors Bros'.
ls_t001w-STRAS = '2 King Street, 3rd floor'.
ls_t001w-ORT01 = 'San John'.
ls_t001w-REGIO = 'N.B.'.
ls_t001w-PSTLZ = 'E2L 1G2'.
ls_t001w-adrnr = '000012345'.
MOVE ls_t001w-adrnr TO gv_addnr_vendor.
else.
MOVE ls_t001w-adrnr TO gv_addnr_vendor.
ENDIF.
Thanks,
mahahe
Hi mahahe,
You could do this checking first before you hardcoded it.
IF GV_ADDNR_VENDOR = ''
READ TABLE it_ekpo into wa_ekpo INDEX 1.
SELECT SINGLE * FROM t001w INTO ls_t001w
WHERE werks EQ wa_ekpo-werks.
if wa_ekpo-werks = '2000' and wa_ekpo-lgort = '5200'.
ls_t001w-NAME1 = 'Connors Bros'.
ls_t001w-STRAS = '2 King Street, 3rd floor'.
ls_t001w-ORT01 = 'San John'.
ls_t001w-REGIO = 'N.B.'.
ls_t001w-PSTLZ = 'E2L 1G2'.
ls_t001w-adrnr = '000012345'.
MOVE ls_t001w-adrnr TO gv_addnr_vendor.
else.
MOVE ls_t001w-adrnr TO gv_addnr_vendor.
ENDIF.
ELSE.
" Get it from table t001w.
ENDIF.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
81 | |
10 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.