Application Development and Automation 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: 
Read only

How to update custom fields through standard BAPI?

Former Member
0 Likes
5,457

Hi All,

In VA03 TCODE we have additional data B tab in which 5 custom fields are present which are appended in VBAP table. I need to update 2 fields in this screen.

I need to use standard BAPI BAPI_CUSTOMERCONTRACT_CHANGE to update but how to include these custom fields in this BAPI.

I tried the steps from function module documentation but it didnt work.

can anyone help me out with this?

Thanks & Regards,

Anjali.

Hi All,

In VA03 TCODE we have additional data B tab in which 5 custom fields are present which are appended in VBAP table. I need to update 2 fields in this screen.

I need to use standard BAPI BAPI_CUSTOMERCONTRACT_CHANGE to update but how to include these custom fields in this BAPI.

I tried the steps from function module documentation but it didnt work.

can anyone help me out with this?

Thanks & Regards,

Anjali.

9 REPLIES 9
Read only

RaymondGiuseppi
Active Contributor
0 Likes
3,057

- Which structures were appended (4 structures per table with customer fields) ?

- How did you fill the EXTENSIONIN table parameter ?

- Is there a step you did not understand in parameter documentation ?

Regards,

Raymond

Read only

0 Likes
3,057

Hi Raymond,

.APPEND    ZADD_DATA_B    STRU    0    0    Fields for Additional Data B Tab

ZEITR                     DEC        3     0    Holding period

ZEITE                     CHAR     1      0    Time unit of time period in indirect date determination

ZCMILE_PLAN        NUMC     6     0    Contract Mileage

ZCONT_REF           CHAR     20    0    Latest Contract rev

ZAMILE_PLAN        NUMC    6      0    Actual mileage

ZACT_RET_DT        DATS     8      0    Actual Return Date

the above structure is appended in VBAP table.

I need to update only last 2 fields i.e ZAMILE_PLAN and ZACT_RET_DT using standard BApi BAPI_CUSTOMERCONTRACT_CHANGE .

I am passing below parameter in Extensionin.

BAPE_VBAP                  000000058100001000011120120615
Read only

0 Likes
3,057

Hi Anjali,

There are some good sap notes are there to update custom fields for other bapi using extension.You can check that.

Regards,

Madhu.

Read only

0 Likes
3,057

- You have to pass also a BAPE_VBAPX record in EXTENSIONIN like

BAPE_VBAPX                 000000058100001    XX

- Your customer field names should have started with ZZ not a single Z (Note 16466 - Customer name range for SAP objects)

Regards,

Raymond

Read only

0 Likes
3,057

Hi,

You can refer the documentation given on the field EXTENSIONIN in BAPI BAPI_CUSTOMERCONTRACT_CHANGE.

In this documentationyour situation is explained very well.

Regards,

Rajesh Akarte

Read only

0 Likes
3,057

I have passed BAPE_VBAPX record in EXTENSIONIN like

BAPE_VBAPX                 000000058100001    XX

it is saying

ORDER_HEADER_IN has been processed successfully

ITEM_IN has been processed successfully

JLR Buy Back/Emp SO 581 has been saved

but those 2 field values are not updated when i check in va03 tcode.

Read only

0 Likes
3,057

Did you

- Set CONTRACT_ITEM_INX-UPDATEFLAG = 'U'

- Call BAPI_TRANSACTION_COMMIT

Regards,

Raymond

Read only

0 Likes
3,057

yes I have done.but it is not updating.

Read only

0 Likes
3,057

Hi,

Just go through this how it is updated for other bapi.

http://scn.sap.com/thread/1966552

Regards,

Madhu.