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

Create MPN material usingBAPI_MATERIAL_SAVEDATA

antony_john
Explorer
0 Likes
753

I am trying to create a Manfacturer Part Number using the BAPI_MATERIAL_SAVEDATA BAPI, even though I am passing the material type HERS and also passing other required values like

MATL_GROUP.

MOVE 'X' TO ls_MatDets_op-MATL_GROUP.

MOVE 'MPNPART' TO ls_MatDets-MANU_MAT.

MOVE 'X' TO ls_MatDets_op-MANU_MAT.

and the internal material number

MOVE lv_matnr TO ls_MatDets-INV_MAT_NO.

MOVE 'X' TO ls_MatDets_op-INV_MAT_NO.

The BAPI gives me an error

Operation not possible (e.g. incorrect material type or plant)

has anyone used this BAPI to create a HERS material reference

Please let me know, it would be of great help

Tony

2 REPLIES 2
Read only

antony_john
Explorer
0 Likes
525

ok guys

I figured out how to get that done, just incase anyone faces this problem

you dont need to select the BASIC_VIEW

MOVE 'NEWHERSMATNR' TO ls_Header-MATERIAL.

MOVE 'A' TO ls_Header-IND_SECTOR.

MOVE 'HERS' TO ls_Header-MATL_TYPE.

*MOVE 'X' TO ls_Header-BASIC_VIEW.

*MOVE 'X' TO ls_Header-SALES_VIEW.

*MOVE 'X' TO ls_Header-ACCOUNT_VIEW.

it will work. Just incase anyone has the same problem.

Tony

Read only

Former Member
0 Likes
525

Can i get any documents for MPN and information regarding configuring MPN?