
This section explains how you can assign numbers automatically in your application.
Im many data structures, you must be able to access database records individually. You do so by using unique keys.
A number range object is an object that is created in the SAP system and contains a defined set of unique character strings. A number range object can be used by business applications to provide database records with unique numbers, to complete the keys of the data records. These numbers can then be used as order numbers or material master numbers, for example.
When a new data record is created in the table Orders, a number is automatically taken from the associated number range object and assigned to the new data record as a unique order number.
The numbers of the number range object uniquely identify data records, as well as providing the option to encode differentiating information. The number can indicate, for example, the type of a material. You can do this by maintaining different intervals within the character set of a number range object.
The management of number range objects also ensures that numbers can only be assigned once.
All dialogs, database accesses, and other tasks required to maintain number range objects and intervals and assign numbers in customer developments can be performed by SAP function modules.