Skip to Content
author's profile photo Former Member
Former Member

To save the data in a custom table using a push button


Dear ABAPers,

In my object , I need to use a push button names "SAVE" that has to save the data that is fetched as a result using selection screen options in to a custom table.

I am able to create to data and use the save button. Need your help to understand the flow of data from the screen to table.

- Regards,

Swapna

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

8 Answers

  • Best Answer
    Posted on Jan 03, 2014 at 04:31 AM

    Hi Swapna,

    In PAI for the push button 'SAVE' what code you write .Please provide the more details.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Jan 03, 2014 at 04:32 AM

    Hi Swapna,

    when you assigned your user command to prompt it to save, the changed data is written to the InfoCube or InfoCubes.

    when we copy changed data from an input-ready query to the planning buffer. The entries are checked when this is done. If the check is successful, the data is copied across.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Jan 03, 2014 at 04:34 AM

    Hi Swapna,

    There are two important events are there.

    1. PBO (Process Before Output) - Before screen display

    2. PAI (Process After Input) - After click any function in screen.

    Arivazhagan S

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 03, 2014 at 04:39 AM

    Hi swapna,

    Kindly explain some more in detail.

    You would aware about module pool programming .where you can create a button and write the insert/ update query in the PAI module .update more information to proceed further.

    Cheers,

    Sanjith N

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 03, 2014 at 04:41 AM

    Hi Swapna,

    The screen flow logic is like an ABAP program in that it serves as a container for processing blocks. There are four event blocks, each of which is introduced with the screen keyword PROCESS:


    • PROCESS BEFORE OUTPUT
    • PROCESS AFTER INPUT
    • PROCESS ON HELP-REQUEST
    • PROCESS ON VALUE-REQUEST



    These links help you.

    http://help.sap.com/saphelp_nw04s/helpdata/en/9f/dbaa3a35c111d1829f0000e829fbfe/content.htm

    http://help.sap.com/saphelp_46c/helpdata/en/fc/eb2e7d358411d1829f0000e829fbfe/content.htm

    With regards,

    Riju Thomas

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 03, 2014 at 04:48 AM

    hi,

    In ALV you just specify the table key field for select options in one screen. In next screen u just have your values there u fix the save button.In that screen u can add the values and finally u can save the data which you created.

    SAPTechnical.COM - Demo on using Table Control

    May be this link will be helpful for your requirement.let me check and tell.

    regards,

    gopi

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 03, 2014 at 06:34 AM

    Hi Friends,

    Thanku for ur helpful answers. Actually I need thee function to be happening in a report program. I will check for the same.

    -Regards,

    Swapna

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Jan 03, 2014 at 07:51 AM

    Hi Swapna,

    Please refer the below my code it will help for you.

    " PAI (Module Process After Input )

    module user_command_9001 input.

    perform get_data.
    case sy-ucomm.
    when 'SAVE'.

    PERFORM SAVE_DATA.
    when 'EXIT'.

    message 'Action Cancelled By User' type 'I' display like 'E'.
    call screen 9003.
    when others.
    endcase.

    endmodule.



    FORM SAVE_DATA.



    Here you can save your data's into custom table with help of modify statement.


    Modify <custom table> from <work Area> .



    Regards,

    Thangam.P

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.