‎2006 Apr 11 8:25 PM
Related to the previous question, the SHIFT command does not recognize the '#' sign over there. it does not eliminate so what I have used before to remove it is.
this is the logic..
if znewlawsoncode+??? na 'abcdefghijklmnopqurstuvwxyz'.
shift znewlawsoncode right by 1 places.
condense znewlawsoncode.
endif.
Because the value for this field varies in length for each record sometimes it is 5 chars or 10 or 25 so how can I check for '#' sign here?
As of now I have encountered the field with a constant field length, this is a different scenario.
Thanks
Vinu.
‎2006 Apr 11 8:50 PM
‎2006 Apr 11 8:49 PM
SEARCH string FOR '#'.
SY-FDPOS contains the offset of the found string or the found word within the field.
Regards.
‎2006 Apr 11 8:50 PM
‎2006 Apr 11 8:51 PM
‎2006 Apr 11 9:03 PM
Tested.... works fine for me.
May be you are wrong.
Check it.
Bye.
‎2006 Apr 11 9:08 PM
Peluka, what you may be testing is using the actual character '#'. But what Vinu is facing is a special character that is there on the file but in SAP it just shows up as '#'. It is not the character '#'.
To test, create a small test file with one line having two values 'A' and 'B'. Seperate them with a tab. Now upload the file into an internal table and see the contents. You will see '#' instead of tab.
‎2006 Apr 11 9:09 PM
‎2006 Apr 11 9:28 PM
Thansk Rich, It worked and is easy way to get rid of the '#' sign.
Vinu.