Skip to Content
avatar image
Former Member

Delete rows of IT using field symbol

Hi All,

I have a field symbol <fs_table> that points to a dynamically created internal table. And I have a field symbol <fs_wa> that points to each row in that table.

How do I delete a row from <fs_table> using <fs_wa>.

In short, I want to write something like

DELETE <fs_table> FROM <fs_wa>

But the above statement doesnot work.

Please suggest me a way of doing the same.

Any suggestions would be of great help.

Regards,

Ashish Walke

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    avatar image
    Former Member
    Feb 15, 2008 at 09:10 AM

    Hi,

    You can either use a LOOP AT... ENDLOOP and the DELETE within the LOOP, or use DELETE .... INDEX.

    Regards,

    John.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hi Ashish,

      Don't worry about the performance as it is an internal table. I'm not able to test in on a system, but the code should be something like:

      LOOP AT <table> INTO <wa>.

      IF <condition>

      delete <table> INDEX syst-tabix.

      ENDIF.

      ENDLOOP.

      Regards,

      John.