‎2011 Oct 21 2:28 PM
Hi all,
I have internal table which has field data(char256).I am storing the data line by line...in some cases the line may be 5 characters or 50 or 150 char...but at the end when i view that table i have many null characters at the begin and end of the line of the internal table...how can i remove those null characters...condense is not working here...
‎2011 Oct 21 3:02 PM
Hi
What do you mean?
If you don't fill fully a line, it's normal to have null chararters on the right and you can't delete them
Max
‎2011 Oct 21 3:02 PM
Hi
What do you mean?
If you don't fill fully a line, it's normal to have null chararters on the right and you can't delete them
Max
‎2011 Oct 21 3:46 PM
Hi,
As Max said this is normal when using char field... If this is an issue, you should use a string type.
Kr,
Manu.
‎2011 Oct 24 9:42 AM
when i use string type..the format is getting changed...so i am using character type...Is there any other way to delete the spaces??
‎2011 Oct 24 10:10 AM
Hi ,
Use Do loop and shift the characters to the left by ignoring the spaces.Move the new values to the result variable.
‎2011 Oct 24 10:41 AM
How to move those values to left side...can u pls send some samplecode..thanks
‎2011 Oct 24 10:47 AM
Hi,
Do your process in following steps,
1. Call a Do.. ENDLOOP.
2. Inside the loop , 1st call FM CONVERSION_EXIT_ALPHA_OUTPUT and pass your input value, The output will
remove all the spaces from left and output will have left bound value.
3. Append the output of step 2 into your internal tables.
Regards,
Anirban
‎2011 Oct 24 11:49 AM
hi,
if you want to delete the tralining and leading spaces for the single field you can use the piece of code. for eg
Shift name left deleting leading space.
Shift name1 right leading trailing space.
Hope it should solve your issue
Regards,
Ahamed.
‎2011 Oct 24 11:49 AM
hi,
if you want to delete the tralining and leading spaces for the single field you can use the piece of code. for eg
Shift name left deleting leading space.
Shift name1 right leading trailing space.
Hope it should solve your issue
Regards,
Ahamed.