on 12-30-2022 4:43 PM
Dear Profis,
am getting the shortdump GETWA_NOT_ASSIGNED on the endroutine. Can you please help me sort it out?
Here below the source code:
TYPES: BEGIN OF ty_dso1,
/bic/zoi_ebeln TYPE /bic/oizoi_ebeln,
oi_ebelp TYPE /bi0/oioi_ebelp,
/bic/zlfdnr_3 TYPE /bic/oizlfdnr_3,
/bic/zmm_chgnr TYPE /bic/oizmm_chgnr,
/bic/zmm_chgin TYPE /bic/oizmm_chgin,
/bic/zmm_aldtm TYPE /bic/oizmm_aldtm,
END OF ty_dso1.
DATA: it_tab1 TYPE SORTED TABLE OF ty_dso1
WITH UNIQUE KEY /bic/zoi_ebeln oi_ebelp /bic/zlfdnr_3
/bic/zmm_chgnr,
wa_tab1 LIKE LINE OF it_tab1.
IF NOT RESULT_PACKAGE[] IS INITIAL.
SELECT /bic/zoi_ebeln oi_ebelp /bic/zlfdnr_3 /bic/zmm_chgnr
/bic/zmm_chgin /bic/zmm_aldtm
UP TO 1 ROWS
INTO TABLE it_tab1
FROM /bic/ammawcdp011
WHERE /bic/zoi_ebeln = <result_fields>-oi_ebeln AND
oi_ebelp = <result_fields>-oi_ebelp AND
/bic/zmm_chgin = 'U'.
ENDIF.
LOOP AT RESULT_PACKAGE ASSIGNING <result_fields> WHERE
/bic/zmm_chgin = 'U'.
CLEAR wa_tab1.
READ TABLE it_tab1 INTO wa_tab1 WITH KEY
/bic/zoi_ebeln = <result_fields>-oi_ebeln
oi_ebelp = <result_fields>-oi_ebelp BINARY SEARCH.
IF sy-subrc = 0.
<result_fields>-/bic/zmm_inldm = wa_tab1-/bic/zmm_aldtm.
ENDIF.
ENDLOOP.
Thank you and regards,
Novice L
Hi,
you are using the field symbol <result_fields> in the where condition before you assign it.
You assign it later in the LOOP.
Therefore you get an error in the select statement.
Torsten
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
77 | |
9 | |
9 | |
7 | |
7 | |
6 | |
6 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.