cancel
Showing results for 
Search instead for 
Did you mean: 

Plantwise number ranges

Former Member
0 Kudos

Dear All,

Can you please suggest me how to create invoice number ranges based on plants.

One of our customer is having 2 plants. They want to maintain the number ranges based on the plants.

Both the plants are in same company code. Billing type also same.

Please suggest.

Regards,

Rajesh L

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Dear,

You can maintain your number range in T.Code VN01.

After maintain the number range, Please contact your ABAP developer. He will create a Z T.Code with using some program.

We can use this program :SAPMZSDINVNR

May be it will help you.

Regards,

Sandip

Answers (2)

Answers (2)

Former Member
0 Kudos

Answered

Former Member
0 Kudos

Hello,

I am also looking for the same solution.

Can you tell me how can i do this.

Pls send me the procedure and code. or else send Removed by Moderator

I am waiting for ur response ASAP.

Thanks in advance.

Edited by: Lakshmipathi on Jul 28, 2010 7:18 PM

Being an old member, dont you know the forum rules NOT to ask any SAP information to personal mail id through this forum ??

Former Member
0 Kudos

Dear Pallavi,

Please find the reply from PKV, he has given the clear logic.

Give the same to your ABAPer. They will be able to develop a logic based on this.

Regards,

Mullairaja

Former Member
0 Kudos

Hi,

First, define the number range based on plant wise in VN01.

For example:

Plant A = P001

Plant B = P002

Your two number ranges may be as followed:

P1 = P001XXXXXXX

P2 = P002XXXXXXX

"xxx* represents the recurring number.

Your requirement can then be achieved using user exit USEREXIT_NUMBER_RANGE found in program RV60AFZZ.

You can then use the following logic to do your coding:

1. Where tcode = VF01 AND VBRK-VKORG = 1000 AND VBRK-FKART = ZF2 or ZF3, ZF4 etc... AND VBRP-WERKS = P001

2. Use internal number range = P1 (i.e. "us_range_intern = 'P1')

3. Repeat the same command for Plant B (i.e. "us_range_intern = 'P2').

Note: In this example I have included the example with inclusion of Sales Org + Billing Type + Plant to arrive at a number range. You may want to define your own restriction(s).

But since you mentioned that the Billing Type are the same, you may want to exclude FKART and allow it to apply to ALL Billing type or alternatively just restrict to ONE Billing type.

Hope this helps.

ABAP would be able to easily assist you with these coding.

Thanks.