05-21-2008 7:36 AM
05-21-2008 7:41 AM
check if initial condition on the internal table.. on which u write the for all entires..
if not itab is initial.
select ...
for all entries in itab.
endif.
05-21-2008 7:43 AM
Hi ,
a) The condition internal table MUST NOT be empty ....or else it will go for pulling all the data records from the intended tables...
b) Key fields MUST be compared
c) Use DELETE ADJACENT DUPLICATAES to the condition Internal table before using it
Reward points if satisfied ..
05-21-2008 7:45 AM
Hi,
While using FOR ALL ENTRIES , check that the internal table you are using for "ALL ENTRIES" is not initial.
SORT the interal table by the key fields you are using in the select query and DELETE ADJACENT DUPLICATES
05-21-2008 7:53 AM
Hi ,
the table which is joining should not be empty
use all the key fields for joining
if the key fields having duplicate entries
copy the values into another internal table which is having the same structure and then using
delete adjasent duplicates by comparing the key fields
it_masterhd[] = it_master[].
IF it_masterhd[] IS NOT INITIAL.
SORT it_masterhd ASCENDING BY gmid.
DELETE ADJACENT DUPLICATES FROM it_masterhd COMPARING gmid.
SELECT gmid gm_descrip FROM z_gmid INTO TABLE it_gmid
FOR ALL ENTRIES IN it_masterhd WHERE gmid = it_masterhd-gmid.
SORT it_gmid ASCENDING BY gmid.
ENDIF.