Auto Values
Jump to navigation
Jump to search
Home > Administration > Data > Auto Values
Introduction
The Auto Values feature lets an administrator define how auto-generated values, such as reference IDs, are constructed. Places where more than a sequence number (000001234) is required, an Auto Value can be modified to include dates, time, location, teams, user IDs and more. There are many situations where this type of sequence is much more preferable over a simple numeric sequences. Some examples include: -
- Shipment numbers
- Document or Article Reference Numbers
- Stock Item Codes
- Asset ID's
- Access Code numbers
Available Auto Value Component Parts
The following lists of component parts are available to construct an auto value.
Name | Description | ||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
seq( z, r ) | A number starting at 1 when the sequence is first used and incremented by one each time the sequence is used and will never be reset for the entire life of the sequence.
| ||||||||||||||||||||||
seqd( z, r ) | A number starting at 1 at the beginning of each day, and incremented by one each time the sequence is used. This is the daily incremental value for this specific sequence instance. See the component 'seq' for and explanation of the optional 'z' and 'radix' parameters. | ||||||||||||||||||||||
seqm( [z], [radix] ) | A number starting at 1 at the beginning of each month, and incremented by one each time the sequence is used. This is the monthly incremental value for this specific sequence instance. See the component 'seq' for and explanation of the optional 'z' and 'radix' parameters. | ||||||||||||||||||||||
seqy( [z], [radix] ) | Will be translated into a number starting at 1 at the beginning of each year, and incremented by one each time the sequence is used. This is the yearly incremental value for this specific sequence instance. See the component 'seq' for and explanation of the optional 'z' and 'radix' parameters. | ||||||||||||||||||||||
date( [part] ) | This function will be translated into the date/time a component of the current date/time based on the analysts current time zone settings. The parameter 'part' is optional, the following are possible: -
| ||||||||||||||||||||||
udate( [part] ) | This function will be translated into the date/time a component of the current date/time based on UTC. The parameter 'part' is optional, the following are possible: -
| ||||||||||||||||||||||
uuid( [type] ) | This function will be translated into a newly generated UUID. The parameter 'type' is optional, the following are possible: -
| ||||||||||||||||||||||
sess( prop_name ) | The current user’s session property. | ||||||||||||||||||||||
param(param_name) | A value passed into the function when invoking the sequence. A sequence that includes this component can not be auto-bound to a table for automatic sequence generation. If the sequence is used for this purpose, any record insert will fail as the sequence will throw an error | ||||||||||||||||||||||
rec( column_name ) | will be translated into the value that will be written to the database record. A sequence that includes this component can only be auto-bound to a table and can not be used through a call to the data::sequenceComplexGetNext API. If it is called directly via the API the sequence will contain "??" in the place where the specified record value should be |
Options
- Name
- Description
- Auto Value Components
- seq(z,r)
- seqd(z,r)
- seqm(z,r)
- seqy(z,r)
- date()
- udate()
- uuid()
- sess(name)
- param(name)
- rec(name)
- Current Value
- Daily Increment
- Monthly Increment
- Yearly Increment
- Time Last Generated