‎2007 May 23 4:19 AM
Hi all,
I know the length of the string i.e. 28 characters. i want to place first 10 charecters ,next 12 charecters ,next 4 charecters in the fields of an internal table respectively. how to do this? pls help me.
Thanks,
Praveena
‎2007 May 23 4:21 AM
itab-fld1 = string+0(10).
itab-fld2 = string+11(12).
itab-fld3 = string+24(4).
append itab.
‎2007 May 23 4:21 AM
itab-fld1 = string+0(10).
itab-fld2 = string+11(12).
itab-fld3 = string+24(4).
append itab.
‎2007 May 23 4:23 AM
You can split the string with use of
String+offset(length).
here offset is the starting position and length is no. of characters starting from offset.
For example string is X and other 3 fields are a1, a2, a3.
a1 = X+0(10).
a2 = X+10(12).
a3 = X+22(4)
‎2007 May 23 4:23 AM
Hi
Do Like tHis..
Data: string(28) .
itab-field1 = string+0(10).
itab-field2 = string+10(12).
itab-field3 = string+22(4).
append itab.
clear itab.
Otherwise if any seperaters are there in the string u can do like this...
split string at '/' itab-f1 itab-f2 itab-f3.
Reward All Helpfull Answers..........