Skip to Content
0
Former Member
Feb 12, 2007 at 11:33 AM

Update issue

27 Views

Hi all ,

I need to make an update statement for a table PA2006.

for which I have picked the records which r required to be updated .

Then in the loop I am trying to update the table ,

but it changes the records except the last one .

Am not able to find the error .

I am enclosing my piece of code ,

just varify if anyting seems to be missing..

code

LOOP AT it_2006_upd INTO wa_2006_upd.

IF wa_2006_upd-ktart = '35'

CONCATENATE sy-datum+6(2) '.'

sy-datum+4(2) '.'

sy-datum+0(4)

INTO g_tdlangu.

UPDATE pa2006 SET sprps = 'X' flag4 = 'F' tdlangu = sy-datum

WHERE pernr = wa_2006_upd-pernr and

subty = wa_2006_upd-subty and

seqnr = wa_2006_upd-seqnr and

begda = wa_2006_upd-begda and

endda = wa_2006_upd-endda and

quonr = wa_2006_upd-quonr

ENDIF.

clear wa_2006_upd.

ENDLOOP.