01-25-2009 9:53 PM
hi Gurus ,
i am facing a very strange problem
i have update couple of z fields in master table VBAK i am writing a normal update statements
but it is not updating the value of that field and setting the sy-subrc to 4 . i am passing just the vbeln in the where clause for updating.
can anyone suggest me why my updating failing.
thanks in advance
regarsd,
khushi
01-25-2009 10:14 PM
Do you really want to update the VBAK table or do you want to update the vbak-structure in a USEREXIT ?
Did you encue the table ?
Greatings
Manuel
01-25-2009 10:14 PM
Do you really want to update the VBAK table or do you want to update the vbak-structure in a USEREXIT ?
Did you encue the table ?
Greatings
Manuel
01-25-2009 11:09 PM
yes i have locked the table .. and i have to update the VBAk table ... i am writing a VBAK update .. but its fai;ing and setting sy-subrc to 4.
please tell me the problem why it is happening.
regards,
khushi
01-26-2009 1:11 AM
Hi,
Can you post your code here so we can investigate more.
Also check the data that you are passing to VBAK. it may contain data that cannot be accepted by the table like same primary keys to other records.something like that.
Regards,
Leonard Chomi
01-26-2009 7:42 AM
Hi,
Try the both way to update the Db table.
1.
DATA wa TYPE scustom.
SELECT SINGLE *
FROM scustom
INTO wa
WHERE id = '00017777'.
wa-discount = '003'.
UPDATE scustom FROM wa.
2. UPDATE VBAK SET Zfield1 = <value> ZFIELD2 = <Value> where VBELN = <VBELN>.
01-26-2009 7:57 AM