07-04-2007 4:47 AM
Hi,
I am getting an error in extented program check as below.
Does not use DESCRIBE to confirm there are records in an internal table before using it in a SELECT as the
target of FOR ALL ENTRIES IN in YV_MARINE_SEL at line 72.
for the below select statement.
SELECT TKNUM VBELN_VA ZZROUTING BOLNR
FROM ZVOCEANBOOKING
INTO CORRESPONDING FIELDS OF TABLE I_SHIPMENT1
FOR ALL ENTRIES IN I_DELIVERY1
WHERE VBELN_VA = I_DELIVERY1-VBELN AND
BOLNR in S_BOLNR AND
ZZCANCELINDICATE NE TEXT-012.
could any one help me,
Regards,
Nithya
07-04-2007 4:52 AM
I believe it is warning you that you should validate that I_DELIVERY1 has contents before you use it in a select e.g. you could use
describe table I_DELIVERY1 lines sy-tfill.
if not sy-tfill is initial.
* do the select here...
endif.
or you could use
if not I_DELIVERY1[] is initial.
* do the select here...
endif.
07-04-2007 4:52 AM
I believe it is warning you that you should validate that I_DELIVERY1 has contents before you use it in a select e.g. you could use
describe table I_DELIVERY1 lines sy-tfill.
if not sy-tfill is initial.
* do the select here...
endif.
or you could use
if not I_DELIVERY1[] is initial.
* do the select here...
endif.
07-04-2007 4:52 AM
hi,
Sorry its not extented program check....... its <b>code checker</b>
07-04-2007 4:58 AM
Hi Kalyani,
Please check the table, the table should be filled and should not initial before using FOR ALL ENTRIES.
<u>Example:here is the code for your reference:</u>
<b>IF NOT I_DELIVERY1[] IS INITIAL.</b>
SELECT TKNUM VBELN_VA ZZROUTING BOLNR
FROM ZVOCEANBOOKING
INTO CORRESPONDING FIELDS OF TABLE I_SHIPMENT1
FOR ALL ENTRIES IN I_DELIVERY1
WHERE VBELN_VA = I_DELIVERY1-VBELN AND
BOLNR in S_BOLNR AND
ZZCANCELINDICATE NE TEXT-012.
<b>ENDIF.</b>
<b>Dont forget to reward points.. if useful......
Cheers !
Moqeeth.</b>