Page tree
Skip to end of metadata
Go to start of metadata

Number Range Buffers


The purpose of this page is to provide a description about the Number Range Buffers available in Financial Accounting and linked each one with the SAP notes available if necessary a more detailed information.


Buffering was created as a solution to performance problems faced with NIRV (number range table) lock described in WIKI Number Range in Financial Accounting (

The reason for this is that NRIV is accessed with a database lock using 'SELECT SINGLE FOR UPDATE'. The interval in the table will then remain locked until the next commit or rollback and additional numbers cannot be retrieved from this interval. This causes a serialization of the application.
If other performance problems arise, the timespan until the COMMIT can become very long indeed. This means that more and more processes wait for NRIV until the system hangs. For more details please check SAP Note 572905.

There are the following buffering types available (for more details please check SAP note 504875):

  • Main memory
  • Local buffering
  • Local buffering with work process ID
  • Parallel buffering
  • Parallel buffering with pseudo ascending document number assignment

The number range activation should be accorded with the financial department because some countries have legal requirements for consecutive numbers for all FI document numbers.

Main Memory

Buffering in main memory should NOT be used because it cannot guarantee the free gaps in the system.  You may only set the main memory buffering if no legal requirement applies to the number assignment. You can display the buffer contents of the main memory using transaction SM56.

This type of buffer avoids performance problems but gaps may still exist and they cannot be documented. The numbers are not assigned chronologically.

For more details please check SAP note 920234.

Local Buffer

Local buffering works with an additional table NRIV_LOKAL to assign the document number per application server and work process. However, a disadvantage of the enhanced buffering method "NRIV_LOKAL" is that processes that are running in parallel continue to lock each other at instance level. Batch jobs that run parallel must wait until the first batch run has been completed before they can be loaded. Please check SAP note 179224 for more details.

The document numbers are usually assigned without gaps, however they are not assigned chronologically.

There may be gaps in the document number assignment at the end of a fiscal year if not all of the numbers were used in NRIV_LOKAL.

Unlike the main these gaps can be documented using the report RSSNR0A1.

Parallel Buffer

Parallel buffer solves the problems of the local buffering with work process ID for parallel batch processes.

The performance is improved if a larger quantity of numbers is used in the buffer - 10, for example. The document numbers are then not assigned in a chronologically ascending order. However it is possible reduces the quantity of number in buffer to 1. The document number assignment comes as close as possible to the behavior of the unbuffered assignment from NRIV, because the number is assigned without gaps and basically in chronologically ascending order.

In case of a rollback the document number is available again for used in the next number assignment but without guarantee the chronologically ascending order. This buffer type uses NRIVSHADOW as buffer table. Gaps cannot only be explained using the report RFVBER00.

For more details please check SAP Note 599157

Parallel Buffering with Pseudo Ascending Document Assignment

For legal reasons, it is sometimes necessary for numbers to be assigned in continuous chronological ascending order. This is a special case of the parallel buffering. Buffer size 1 is automatically used, regardless of the quantity of numbers used in the buffer in transaction SNUM.

In the case of a rollback, the assigned document number is no longer available. Using the table NRIV_RESTE, these gaps can be documented using the report RSSNR0S1.

This special case of parallel buffering cannot be activated using Customizing, but requires a modification involving an exit in the application.  In SNUM you set parallel buffering for object RF_BELEG with numbers in buffer = 1. But in SNUM you cannot activate parallel buffering with pseudo ascending number assignment. For this you have to set in BTE 00001170 function exporting parameter E_NO_BUFFER to 'S'.  For more details please check SAP Notes 834257,  599157.

If rollback occurs update task will not be triggered and document number will not be assigned you will not find an entry in document header table BKPF. But number not assigned due to rollback will be stored in table NRIV_RESTE.

BTE 00001170

In BTE 00001170 you have the possibility to only activate/deactivate the

buffering for certain number ranges and company codes. This allows you

to adapt the buffering to your business requirements.

For more details please check point 11 of SAP Note 449030. It is:

 Create and activate your user exit as follows:

    o  Copy the sample function module SAMPLE_PROCESS_00001170 to a separate function module and adjust the copy to your requirements.

    o  Define a "product" in the table TBE24 and set the 'Active' indicator.

    o  Define the name of your function module in the table TPS34. Leave the 'Application' and 'Country' fields blank since the process is not country-specific or application-specific.


Regarding BTE 00001170, you should be able to find it with transaction BERP.

Enter 00001170 in field Process Interface and execute. Click documentation in the result list. You will get the document for it.

The general process to implement one BTE is:

 1. BF24: Define and activate your product

 2. Create your own Function module by copying SAMPLE_PROCESS_00001170

 3. BF44: Assign your function module to process  00001170


Related Documents

Number Ranges in Financial accounting

FAQ - Buffering activation for FI documents

Related SAP Notes/KBAs

SAP Note 83020: What is consulting, what is support

SAP Note 572905 : NR: Unbuffered number ranges

SAP Note 504875 : Buffering number ranges

SAP Note 920234 : Mechanism to fill the number range buffer  

SAP Note 179224 : for unbuffered number ranges  

SAP Note 599157 : Number ranges: new buffering method  

SAP Note 179224 : for unbuffered number ranges  

SAP Note  834257 : FI document number assignment: Buffering using BTE 1170

SAP Note 449030 : FB01: Deactivating number range buffering at interval level  

  • No labels