on 10-10-2005 10:26 PM
I have appended a field to the extract structure of a DataSource.
The main body of the code is as follows
TABLES: QMIH, /TPISP/YI_NONSAP.
DATA: L_S_ZOXTG20045 LIKE ZOXTG20045.
LOOP AT I_T_DATA INTO L_S_ZOXTG20045.
L_TABIX = SY-TABIX.
IF L_S_ZOXTG20045-IWERK IS INITIAL.
SELECT SINGLE AUSBS FROM QMIH
INTO L_S_ZOXTG20045-ZZBW_IMP_DATE
WHERE EQUNR = L_S_ZOXTG20045-EQUNR
AND BAUTL = L_S_ZOXTG20045-RK_MATNR.
ELSEIF L_S_ZOXTG20045-IWERK+0(2) = ZZ.
SELECT SINGLE RK_IMPLEMENT_DT FROM /TPISP/YI_NONSAP
INTO L_S_ZOXTG20045-ZZBW_IMP_DATE
WHERE EQUNR = L_S_ZOXTG20045-EQUNR
AND RK_MATNR = L_S_ZOXTG20045-RK_MATNR.
ELSE.
SELECT SINGLE AUSBS FROM QMIH
INTO L_S_ZOXTG20045-ZZBW_IMP_DATE
WHERE EQUNR = L_S_ZOXTG20045-EQUNR
AND BAUTL = L_S_ZOXTG20045-RK_MATNR.
ENDIF.
MODIFY I_T_DATA FROM L_S_ZOXTG20045 INDEX L_TABIX.
ENDLOOP.
I am getting an error when I try and activate. The details are:
Field 'ZZ' is unknown. It is neither in one of the specified tables nor defined by a DATA statement. However ZZ is meant to represent the first two characteristics of a field IWERK. I cannot see any problems could anyone assist. Thanks
Try this,
use a variable with assignment L_S_ZOXTG20045-IWERK+0(2) and than use the variable in elsif.
I think this is the problem.
Regards.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I don't know why it gives you this error, but i think you have to put another ENDIF.
Regards.
Paolo
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
24 | |
12 | |
9 | |
7 | |
6 | |
5 | |
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.