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: 

error in bapi_goodsmvt_create

Former Member
0 Kudos
558

hi,

im using bapi_goodsmvt_create in my program to create transfer posting. data flow is perfect in my program but document no. is not getting created. the bapi_return gives a

error msg : ' NUMBER RANGE FOR TRANS./EVENT TYPE WA IN YEAR DOES NOT EXIST'.

can anyone say whats wrong in my prog. or wat does the above error mean.

points wil be rewarded.

regards

mano

1 ACCEPTED SOLUTION

Former Member
0 Kudos
331

Hi Mano,

This is not a problem in your program, it is probably caused because of a missing customizing (SPRO) activity.

The bapi_goodsmvt_create creates a Material Document for the goods movement. The Mat.Doc. has a number range which is managed in the customizing. If a number range is not defined (for the right year) this message is issued.

To define the number range, go to trnx SPRO -> SAP Reference IMG -> Materials Management -> Inventory Management and Physical Inventory -> Number Assignment -> Define Number Assignment for Material and Phys. Inv. Docs - execute it. Another way is trnx OMBT (it gets u to the same place, i just specified the full path in customizing because some find it easier to remember). There u have to choose the change intervals button and define a number range with the right year (u will find the insert option in the menus at the top of the screen under edit). After doing that try running the bapi again, u shouldn't get this message now.

Good luck...

Igal

3 REPLIES 3

Former Member
0 Kudos
332

Hi Mano,

This is not a problem in your program, it is probably caused because of a missing customizing (SPRO) activity.

The bapi_goodsmvt_create creates a Material Document for the goods movement. The Mat.Doc. has a number range which is managed in the customizing. If a number range is not defined (for the right year) this message is issued.

To define the number range, go to trnx SPRO -> SAP Reference IMG -> Materials Management -> Inventory Management and Physical Inventory -> Number Assignment -> Define Number Assignment for Material and Phys. Inv. Docs - execute it. Another way is trnx OMBT (it gets u to the same place, i just specified the full path in customizing because some find it easier to remember). There u have to choose the change intervals button and define a number range with the right year (u will find the insert option in the menus at the top of the screen under edit). After doing that try running the bapi again, u shouldn't get this message now.

Good luck...

Igal

0 Kudos
331

hi im getting different error now.

it says storage location zpl3 not supported.

whether its prog error or functional error. need help?

regards

mano

0 Kudos
331

Hi Mano,

1st - if u have another message this means the previous problem is solved which is good...

Now the problem u r facing is the definition of a storage location (again, it's a customizing issue).

The storage locations u entered in the bapi parameters must be defined, and it must be in the plant u entered in the bapi parameters.

To define a storage location, again go to SPRO -> SAP Ref. IMG -> Enterprise Structure -> Definition -> Materials Management -> Maintain storage location. When u enter u will be prompt for the plant. Make sure your Stor.Loc. exists and is defined under your plant. Now u can run the bapi again.

Pls reward points if helpful.

Good luck

Igal

P.S: all these problems are MM customizing issues that should have been done in your system by an MM consultant or the MM people in your organization. I'm a development consultant, not MM, i happen to know how to solve the problems u mentioned, but surely any MM person will be more helpful to u then i. I don't mind helping, but if u have an MM person near by, u will finish your task much faster....