Application Development and Automation 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: 
Read only

insert row in alv grid

Former Member
0 Likes
1,350

My Requirement : when i click on in-built button 'INSERT ROW' in alv grid and add data to this row then on click of save button on standard toolbar( for which i have given the coding(using modify db table statement ) ) then the database is  updating ....

BUT the PROBLEM is that with this inserted record a extra record is also inserted at the top of table with  default 0000000000 value in the key fields ... i dont know why it is happening ...can anyone help in this regard...

1 ACCEPTED SOLUTION
Read only

manish_shankar
Participant
0 Likes
999

Hi Sandeep,

May be you are inserting one empty rows also.

Better you debug your code, you'll get the solution.

- Thanks,

Manish Shankar.

My Requirement : when i click on in-built button 'INSERT ROW' in alv grid and add data to this row then on click of save button on standard toolbar( for which i have given the coding(using modify db table statement ) ) then the database is  updating ....

BUT the PROBLEM is that with this inserted record a extra record is also inserted at the top of table with  default 0000000000 value in the key fields ... i dont know why it is happening ...can anyone help in this regard...

6 REPLIES 6
Read only

manish_shankar
Participant
0 Likes
1,000

Hi Sandeep,

May be you are inserting one empty rows also.

Better you debug your code, you'll get the solution.

- Thanks,

Manish Shankar.

Read only

0 Likes
999

thanks manish... actually there was some problem in the code itself...

Read only

iftah_peretz
Active Contributor
0 Likes
999

Hi,

Can you give a snipp it of the code when the button is pressed so we can go over it?

Best,

Iftah

Read only

0 Likes
999

thanks for the reply lftah....the problem has been solved...

Read only

sachin_yadav3
Active Participant
0 Likes
999

Hi Sandeep,

As per you there is  "in-built button 'INSERT ROW' in alv grid "  but when i checked on ALV output there is not such button. Could you please specify bit more on this functionality (i.e in buit functionality of INSERT) so that it can be useful to others.

Thhanks & Regards

Sachin

Read only

0 Likes
999

hi sachin ,

     

  At run time these buttons are automatically created  on the alv grid's menu toolbar ,

BUT if your alv is not editable then insert button will not appear , so first make it editable and then check the output , you will surely get all the buttons there...

thanks

regards

sandeep