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: 

Database Update

Former Member
0 Kudos

HI all,

I am updating a databse table in loop using a subroutine in which i

need to update date field of this table with system date, the other fields are

being updated successfully.

In loop it is working fine.

But once I come out of the loop it is showing all zeros instead of sy-datum for date field.

I have used commit work also.

It is urgent, Please help.

Thanks,

Mungala.

4 REPLIES 4

Former Member
0 Kudos

Hi,

Please make sure that the date field in database table has data element sy-datum.

Thanks

Arun.

Former Member
0 Kudos

hi,

when u are using a perform in a loop

you have to send the table to that form

like PERFORM LIST_HEADER TABLES GIT_HEADER

then it will be updated..

reward points if helpful

regards,

venkatesh

Former Member
0 Kudos

Hi

Better Declare the Internal Table which you are using for Update, similar to the Database table structure and use UPDATE/Insert from ITAB.

it will insert/update all fields

Reward points for useful Answers

Regards

Anji

Former Member
0 Kudos

Hello praveena,

check the date format in your table.

sy-datum uses Date field (YYYYMMDD) stored as char(8)

Regards