‎2008 Apr 15 6:25 AM
Dear friends,
i have to take data for VBAK-ERNAM. while pulling data, i have some are numbers and some are names. i need to pull only names.
Ex: ernam contains
825569
860070
Rakesh
Ramesh
564896
Kumar
I need to pull only
Rakesh
Ramesh
Kumar
it should not take numbers
How to do this ?
Please let me know
Thanks & Regards,
Ajay
‎2008 Apr 15 6:30 AM
hi,
First you have to get all values in your itab.
Then you can filter values having only numbers using if condidtion.
if itab-field co '0123456789'.
delete itab.
endif.
‎2008 Apr 15 6:30 AM
hi,
First you have to get all values in your itab.
Then you can filter values having only numbers using if condidtion.
if itab-field co '0123456789'.
delete itab.
endif.
‎2008 Apr 15 6:36 AM
I have done like this
LOOP AT ITAB.
IF itab-ernam CO '0123456789'.
DELETE itab.
ENDIF.
ENDLOOP.
But it is not working
Plese suggest
thanks,
Ajay
‎2008 Apr 15 6:37 AM
create a select option using pattern like 0, 1,....9* add these values to ur select option. and then based on that u can move the values.
try it.
‎2008 Apr 15 6:42 AM
Dear Madhavi,
Actual requirement is i have provided F4 help to ERNAM. For this field in data base somany numbers are there. But i need to pickup only names not numbers.
So i have taken whole data into itab.
From that itab i need to filerize the data for fetching only names.
Kindly suggest in this
Thanks ,
Ajay
‎2008 Apr 15 7:25 AM
‎2008 Apr 15 6:42 AM
Hi Ajay,
Select -
ernam -
into table itab
from vbak
where............
........................
Now in ur itab all the data vbak-ernam are stored with numeric & charecter type record.
now u jsut foolow the code
Loop at itab.
if itab-ernam co '0123456789'.
delete itab.
endif.
endloop.
It will work fine.
If it is helpfull pls reward pts.
Regards
Srimanta
‎2008 Apr 15 6:44 AM
Hi,
first pick all the data from the database,
Then you can filter that.
***********
lv_abcde = sy-abcde.
loop at it_vbak.
if not it_vbak-ernam NA lv_abcde.
write: it_vbak-ernam.
else.
delete itab.
endif.
endloop.
***********
It will help if ernam contains name like 'D1000'.
Regards,
Bhanu
Edited by: Bhanu P on Apr 15, 2008 7:45 AM
‎2008 Apr 15 6:46 AM