‎2008 Mar 17 8:36 AM
How do you clear data already written using the 'WRITE' syntax?
‎2008 Mar 17 9:07 AM
Hi Siddarth,
While writing data to a list output u can over write the already written data only if your cursor is there in the same line. If the cursor is moved to the next line using the syntax WRITE:/ or
SKIP or NEW-LINE u can't return back the previous line.
Check below sample code for over writing the data which is already written to the list output.
DATA w_space(5) TYPE c VALUE IS INITIAL.
WRITE:/1 'Vinod'.
WRITE: 1 w_space.
O/P: Blank.
u can over write data by specifyings the position from where u want to over write also.
WRITE AT 3 w_space.
O/P: Vi
Thanks,
Vinod.
‎2008 Mar 17 8:53 AM
Hi,
Clear that Work Area....in which the data is stored runtime.
CLEAR WA_IT.
HTH
Regards,
Dhruv Shah
‎2008 Mar 17 9:00 AM
Hi,
Just use CLEAR ITAB before WRITE STATEMENT.
Award Points If Useful
‎2008 Mar 17 9:01 AM
hi ,
check this ......
data: v_test(23).
write 'this is working boss' to v_test.
write:/ v_test.
write 'this is working boss' to v_test.
clear v_test.
write:/ v_test.
regards,
venkat.
‎2008 Mar 17 9:01 AM
Hi,
As mentioned above, you can clear the variable before it is being displayed using WRITE statement. Otherwise, you cannot do anything once it is displayed.
Hope it helps...
P.S. Please award points if it helps...
‎2008 Mar 17 9:07 AM
Hi Siddarth,
While writing data to a list output u can over write the already written data only if your cursor is there in the same line. If the cursor is moved to the next line using the syntax WRITE:/ or
SKIP or NEW-LINE u can't return back the previous line.
Check below sample code for over writing the data which is already written to the list output.
DATA w_space(5) TYPE c VALUE IS INITIAL.
WRITE:/1 'Vinod'.
WRITE: 1 w_space.
O/P: Blank.
u can over write data by specifyings the position from where u want to over write also.
WRITE AT 3 w_space.
O/P: Vi
Thanks,
Vinod.