Sequences
A sequence (also called a “generator” in Firebird) is a stored variable containing a shared value for different tables and data. Sequences generally serve to implement the current auto-increment values in databases tables. To show the “Sequences” management dialog box, select “Project | Sequences”.
Note that sequences are not supported by all the RDBMSs compatible with ERBuilder Data Modeler. For example, MySQL does not support sequences, whereas Firebird does.
![Sequences](dist/img/Help ERBuilder 7.0.4 to generate CHM final2_fichiers/image113.jpg)
Creating a new sequence
To create a new sequence:
- Select
in the “Sequences” management dialog box.
- Specify the sequence caption (and eventually its name) and necessary parameters according to the used RDBMS then click
to save the added sequence.
The following table gives a brief explanation for the possible sequence characteristics:
Sequence characteristics Type Possible values Description Seed Integer An integer The start value of the sequence Increment Integer An integer The step value of the sequence Maximum value Integer An integer The upper limit for the possible sequence values Minimal value Integer An integer The lower limit for the possible sequence values Cycle Enumerate “Cycle”, “No Cycle” Specifies if the sequence comes back to the lower limit value after reaching the upper limit value Cache Enumerate “Cache”, “No Cache” Specifies if the RDBMS is going to store a limited number of the next sequence values in cache for quicker access (cache size must not be null) Integer type Enumerate “TINYINT”, “SMALLINT”, “INT”, “BIGINT”, “DECIMAL”, “NUMERIC” Specify the sequence type Order Enumerate “Order”, “No Order” Specify if the RDBMS is going to generate the sequence values in natural order (useful in a Real-time Application Cluster)
![new sequence](dist/img/Help ERBuilder 7.0.4 to generate CHM final2_fichiers/image114.jpg)
Available in: Standard, Professional and Enterprise Editions.