Skip to Content
-1

display only the selected rows in interactive alv

So I have created an alv with records. My requirement is once I select the record,only those records have to be displayed and edited and get saved. editing and saving part is done. Please help me with displaying only the selected rows. pfa.

zd3.txt (7.6 kB)
Add comment
10|10000 characters needed characters exceeded

  • Not retrieving the entire report again, you do refresh the internal table only. not going again though all the logics again

  • How do you refresh the internal table? Retreiving data again to fill and refresh your internal table, the one you suggested to delete rows from.

    This could lead to long waiting time which is a really poor user experience.


    The other option is to use a copy of the same table, but, again, you can have an issue with memory if the data is huge.

  • This can be achievable either way, as you said it totally depends on the situation of the Program and the no. of records it is handling!

    Deleting the rows will not take much time and even throwing the data to a temporary table is also okay. but that also depends on the No. of records as you said. it may lead to issues with memory.

    It is up to you to optimize the program!

  • Get RSS Feed

3 Answers

  • Apr 09 at 07:23 AM

    Without reading your code, this is how i'd set up my flow:

    1. Retrieve my data and show the alv
    2. Mark interested lines and press a specific button
    3. Editable ALV popup with selected fields
    4. Once the user confirms the changes, i update my initial ALV and refresh it, closing the popup.
    Add comment
    10|10000 characters needed characters exceeded

  • Apr 05 at 07:10 PM

    Hi Dyvia,

    I recommend you starting to understand how ALV ABAP OO works.

    Suggested SAP link below.

    https://help.sap.com/doc/erp2005_ehp_06/6.0.6/en-US/4e/b7a512999e0134e10000000a42189b/frameset.htm

    Regards,

    Add comment
    10|10000 characters needed characters exceeded

  • Apr 06 at 09:10 AM
    -2

    hi

    i have modified your sample code. see attached file.

    demo.txt

    Add comment
    10|10000 characters needed characters exceeded