cancel
Showing results for 
Search instead for 
Did you mean: 

SD - Billing - External Number Range

Former Member
0 Kudos

Hi,

I have two questions related to SD billing document numbering:-

1. I am getting error message of [Please specify an internal number range Message no. NR752] while saving a billing document based on the delivery. I have checked only external number range box in VN01. Do I need to use any user-exit for this? If yes then there are 2 user exits available -


a) USEREXIT_NUMBER_RANGE_INV_DATE USING US_RANGE_INTERN in program RV60AFZC

b) FORM USEREXIT_NUMBER_RANGE USING US_RANGE_INTERN in program RV60AFZZ

but both the cases the variable is US_RANGE_INTERN which is not allowing external number range ID to pass. How this external no range works.?

2. I have a business requirement for our Mexican company code on external alphanumeric number. There would be 3 billing types say, ZF2, YF2 and ZYF2. Mexican government provides Invoice numbers in advance.

ZF2 Number range would be A001 to A999

YF2 Number range would be B001 to B999

ZYF2 Number range would be C001 to C999.

All these Invoices would be created at same time. i.e. parallel processing. Also all these invoices would be transmitted thru EDI -IDOC. And accounting document should have same number as billing document will carry i.e. external govt provided numbers.

How do I map this in systems. My experience says alphanumeric number range is not supported by SAP. Anybody may share his solution on this would be simply great.

Thanks

Subrata Das

Accepted Solutions (0)

Answers (7)

Answers (7)

Former Member
0 Kudos

Post to SAP. There might be a country specific solution!

Regards,

GSL.

Former Member
0 Kudos

Use internal number ranges (only numeric) and trigger the number range interval from the zee table which you are maintaining. We have done this at many places.

I think you need to convince your client on using numeric number series instead of alpha numeric. For eg: if client wants to use for India company code number series as IN100001 to IN199999 then you can codify IN as 10 and then the number series can be 10100001 to 10199999.

Regards,

GSL.

Former Member
0 Kudos

Hi GSL,

Thanks for your info...........

That is not happening here....they don't want to listen...since mexican government issue these alpha numeric number ranges 20 times in a year to my client hence it seems to be very critical for them to use alphanumeric number range.

Let's see what happens ...........anyway thanks guys

Subrata Das

Former Member
0 Kudos

Hi Som,

Thanks for your info..........

I have done the same thing whatever you have mentioned but it is not working. In the custom table we define the number range ID only with no number range interval. Interval we define at VN01. If it is checked externally in VN01 system doesn't recoznise any externally checked number range interval ID. Because the variable is US_RANGE_INTERN. {Table zbd_nr_code , here we provide only Internal number range ID not externally checked number range interval ID}

It always pass the internal number range ID. I am getting the error of "Internal number range is missing". I am not sure whether there is any variable for external number range checked interval ID in SAP. If I can get that variable hopefully it should pass the externally checked number range interval ID. Your solution is perfect for internal number range but it doe's not work for external number range checked interval ID.

Thanks

Subrata Das

Edited by: Subrata Das on Sep 22, 2008 10:00 PM

Former Member
0 Kudos

FORM USEREXIT_NUMBER_RANGE *

----


  • This userexit can be used to determine the numberranges for *

  • the internal document number. *

  • US_RANGE_INTERN - internal number range *

  • This form is called from form LV60AU02 *

----


FORM USEREXIT_NUMBER_RANGE USING US_RANGE_INTERN.

  • Example: Number range from TVFK like in standard

  • US_RANGE_INTERN = TVFK-NUMKI.

*{ INSERT DEVK905392 1

----


  • There was a need to check whether all the mandatory pricing

  • conditions have been filled before creation of an invoice so that

  • the invoice is released to accounting as and when it is created.

  • Piece of code written below ensures the same. Field uvprs = 'X'

  • in item table indicates that the item is incomplete with respect to

  • pricing.

LOOP AT xvbrp WHERE uvprs = 'X'.

EXIT.

ENDLOOP.

IF sy-subrc EQ 0.

MESSAGE e073(vf) WITH xvbrp-posnr.

ENDIF.

----


TABLES : zbd_nr_code.

data : aa like zbd_nr_code-nr_code.

IF sy-tcode = 'VF01'.

  • SELECT SINGLE *

  • FROM tvko

  • WHERE vkorg = vbak-vkorg.

*

  • IF sy-subrc EQ 0.

SELECT SINGLE NR_CODE INTO ZBD_NR_CODE-NR_CODE

FROM zbd_nr_code

WHERE vkorg = vbrk-vkorg

AND werks = vbrp-werks

AND fkart = vbrk-fkart.

IF sy-subrc = 0 .

us_range_intern = zbd_nr_code-nr_code.

ENDIF.

  • ENDIF.

ENDIF.

I feel this will help out.

Regards

Former Member
0 Kudos

Hi,

1. Number Rage are use to define what number to be assign to sales document type. Number range can be assign Internal or external.

In internal number range system automatically assign a number to sales document according to number range define in system.

In External number range user manually assign number to sales document.

For Assigning Number Range use T-Code VN01

Choose Intervals -


Define your number range

Please take a reference:

http://help.sap.com/erp2005_ehp_03/helpdata/EN/6e/f47c5328c1604ab55bcfcd88080306/frameset.htm

http://www.sap-img.com/sap-sd/number-ranges-in-sales-order.htm

http://help.sap.com/erp2005_ehp_03/helpdata/EN/d8/731d5c4b7511d1894b0000e8323c4f/frameset.htm

2. Alpha-Numeric Number Range could be achieved "Externally" and can't be maintained "Internally".

The major draw-back is that one has to keep track of current running number.

Best Regards,

Amit.

Former Member
0 Kudos

U have two user exits. Just note down the table in which u need to make an external number range.

ie u can create number ranges and assign to external z table created.

For example for sales org,plant and order type you can mainatin a number range series.

and u can specify the number ranges as specified.

in SE16 for the particular table u can create enteries and update database successfully..

In the specifed user exit create a z table of clients requirement and trigger for the same.

Regards

Former Member
0 Kudos

Hi,

1. Assign number range for billing type in VOFA. Choose billing type that you use and assign number range for it.

Regards,