2012 Jun 07 10:45 AM
Hi all,
I Have a problem for Update syntax.
please see code below:
UPDATE ekpo
SET: oic_oland1 = wa_xekpo-oic_oland1 "Country
oic_oregio = wa_xekpo-oic_oregio "Region
umren = wa_xekpo-umren. "QTY conversion
Using this the table for EKPO should be updated but it did not..
did i miss something here.. for me to update directly on EKPO..
Thanks in advance..
Well appreciated your response..
2012 Jun 07 1:44 PM
Hi beginners,
NEVER ( means N E V E R) update a SAP standard table other than using Functions module, BAPIs, BaDi, Transaction provided by SAP.
Or ask the business revision department first 🙂
Regards
Clemens
2012 Jun 07 10:49 AM
u should mention the purchase order to be updated.Pls search in SCN before u post
2012 Jun 07 10:58 AM
Hello Karthik
I already did that specifying the Purchase order item.
But it same it did not update the EKPO..
actually the code i paste is it takes time to update the EKPO...
2012 Jun 07 3:14 PM
ABAPER SAP wrote:
actually the code i paste is it takes time to update the EKPO...
Probably because the code you have posted will try to update every record in EKPO. But when it dumped, fortunately it rolled back your attempt to change it.
Clemens Li was right - don't do this.
Rob
2012 Jun 07 11:08 AM
Hi,
Try this,
CALL FUNCTION 'ENQUEUE_E_TABLE'
EXPORTING
MODE_RSTABLE = 'E'
TABNAME = 'EKPO'
EXCEPTIONS
FOREIGN_LOCK = 1
SYSTEM_FAILURE = 2
OTHERS = 3.
UPDATE EKPO SET BUKRS = '1000'
LOEKZ = 'X'
STATU = 'F'
WHERE EBELN EQ '45000001'
AND EBELP EQ '0010'.
CALL FUNCTION 'DEQUEUE_E_TABLE'
EXPORTING
MODE_RSTABLE = 'E'
TABNAME = 'EKPO'.
Regards,
Danish
2012 Jun 07 1:44 PM
Hi beginners,
NEVER ( means N E V E R) update a SAP standard table other than using Functions module, BAPIs, BaDi, Transaction provided by SAP.
Or ask the business revision department first 🙂
Regards
Clemens
2012 Jun 07 3:20 PM
Never
- use UPDATE SET without WHERE clause
- update a standard table with open sql (or use an update task FM)
I don't have access to an IS-OIL system, but you should look for BAPI* structures using the data element of the fields you want to update, and then look for BAPI using those structures. If not found look, via transaction BAPI, for a generic BAPI on purchase orders with an EXTENSIONIN parameter.
Regards,
Raymond
2012 Jun 08 3:01 AM
Hello ALL,
Thanks for all the response..
I already configure the logic.. and not it is working..
Question answered..
I need to use update syntax.. cause the FM did not automatic update my Purc. Doc item..
to update direct the table automativ upon execution.. i also use WAIT syntax.