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: 

Assign external # range to Requisition using BAPI_REQUISITION_CREATE

former_member498918
Participant
0 Kudos
210

I am using BAPI_REQUISITION_CREATE to create a Requisition with a specified number. The number is in the External Number range of the document type. When I create the Requisition in transaction ME51N I can assign the number I require. However, when I try to assign the same number range using the BAPI it says the number is not in the number range.

I am converting the number using the ALPHA convert function, but the BAPI still complains that the number is not in range.

Does anyone know if I need to do something in the BAPI settings to get it to accept the External Number range for the document type.

Thank you

Karen

4 REPLIES 4

Former Member
0 Kudos
97

I would guess that external/internal number assignment is configured for the requisition document types? In other words, whether or not the numbering is internal or external may be a all-or-nothing configuration setting, based on document type. Check with your functional specialist....

0 Kudos
97

I'm sure the number range is setup correctly as it is allowing the external number to be assigned when I use the transaction ME51N.

We only have one number range assigned to the document type NB. The BAPI is allocating the correct internal number if I leave the number blank, but complains that the external number is not in range.

Any other ideas?

0 Kudos
97

Sorry, no other ideas...I'd have to watch the process in debug, to see why SAP doesn't like the number supplied, how the error is called, etc.

0 Kudos
97

We did a system restart and now the number range is recognised by both ME51N and the BAPI?? So problem is solved with no changes required??