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: 

Updating Sales order with BAPI_SALESORDER_CREATEFROMDAT2

Former Member
0 Kudos
372

Hi All ,

I am not able to Update two Zfields in vbap using FM BAPI_SALESORDER_CREATEFROMDAT2, In create mode I am able to save values into those fields .

I have checked the fields in structures

ZZVBAP (append structure of VBAP)

ZZBAPE_VBAP (append structure of BAPE_VBAP)

ZZBAPE_VBAPX (append structure of BAPE_VBAPX)

ZZVBAPKOZ (append structure of VBAPKOZ)

ZZVBAPKOZX

what could be the other reason for these zfields not saving in update mode .

Thanks

Vinay Kolla

3 REPLIES 3

Former Member
0 Kudos
95

Hi....

You have to write Wrapper Bapi for

BAPI_SALESORDER_CREATEFROMDAT2

in which you will call standard bapi BAPI_SALESORDER_CREATEFROMDAT2 and as well as code for adding the fields to Zfields.....

Take Care...

..Ashish

Former Member
0 Kudos
95

You can use implicit enhancement to include new fields to be added in BAPI. Because in BAPI, field by field mapping is there. just find FM "sd_salesdocument_create" and then find where ITEM details are to be filled.

If you still have problem, reply back,,, because I just worked in thsi BAPI for same scenario.

Former Member
0 Kudos
95

Thanks Guys ,

The issue is resolved , the reason for that two fields not updating was the order of these fields is different in VBAP and BAPE_VBAPX .

Regards

Vinay kolla