Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

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

Former Member
0 Kudos


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

1 ACCEPTED SOLUTION

former_member424229
Participant
0 Kudos

Hi Swapna,

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

9 REPLIES 9

former_member424229
Participant
0 Kudos

Hi Swapna,

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

former_member187748
Active Contributor
0 Kudos

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.

arivazhagan_sivasamy
Active Contributor
0 Kudos

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

Former Member
0 Kudos

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

Former Member
0 Kudos

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

Former Member
0 Kudos

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

Former Member
0 Kudos

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

0 Kudos

Hi Swapna,

please refer to my previous messages, in which i have defined you how, the save attributes works.

thangam_perumal
Contributor
0 Kudos

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