2007 Jun 13 6:09 AM
can u please tell to code to check internal table for no record. i want to check the content of internal table and write code if internal table has no record. my internal table name is wa
please help
2007 Jun 13 6:12 AM
if wa[] is initial.
message 'No records in internal table!!' type 'E'.
endif.
can u please tell to code to check internal table for no record. i want to check the content of internal table and write code if internal table has no record. my internal table name is wa
please help
2007 Jun 13 6:11 AM
if itab[] is initial.
message 'No data ' type 'E'.
else.
loop at itab.
write : ...
endloop.
endif.
regards
shiba dutta
2007 Jun 13 6:11 AM
hi,
if not wa[] is initial.
message 'no records are avbl'.
esle.
your logic.
endif.
reward points if useful,
regards,
seshu.
2007 Jun 13 6:11 AM
2007 Jun 13 6:11 AM
Hi,
Check this..
DESCRIBE TABLE WA.
IF SY-TFILL IS INITIAL.
WRITE: / 'No records'.
ENDIF.
Thanks,
Naren
2007 Jun 13 6:12 AM
if wa[] is initial.
message 'No records in internal table!!' type 'E'.
endif.
2007 Jun 13 6:12 AM
hi,
chk this.
if itab[] is initial.
*no data.
else
*data available.
endif.Rgds
Anver
2007 Jun 13 6:15 AM
hi..
Use loopat for your requirement .When there is any record in the internal table sy-subrc is 0, otherwise if internal table has no records then the sy-subrc will set to 4. (or )use describe to get number of records .If number of records or zero.You can write the code as per your requirement.
regards,
veeresh