Autonumber Datatype

Autonumbers are a system feature that generate a sequential number following a specific pattern. For example, this allows the system to generate license numbers like “ABC001”, “ABC002”, etc.

See also: Autonumber Attribute

Overview

Autonumbers are used to generate sequential alphanumeric “numbers” following a pattern. They are used in many places in LearningBuilder:

  • Unique Identifier on a Member Role

  • Activity Number for an Activity

  • As Extrinsic workflow attributes using the Autonumber Attribute data type

Details

Autonumbers are comprised of a “mask”, which sets the pattern, and a “seed”, which controls the sequential ID generation.

The following Intrinsic Attributes use the autonumber functionality:

  • Activity ID (aka Activity Number) on an Activity Definition

    • Assigned when a new Activity is created.

    • The entire system uses the same Autonumber definition.

    • Updates to the mask or seed require an IA support ticket.

    • The assigned number can be updated later if configured as an editable input field.

  • Unique ID

    • Assigned when a new Role is created (not Granted)

    • Each role has its own Autonumber definition

    • The definition can be updated on each role (after 11.0, the current seed can also be updated)

    • The assigned number can be updated later if configured as an editable input field.

Autonumbers can be added as an Extrinsic Field to any workflow. When used as an Extrinsic Field:

  • Assigned when it is an input attribute on a workflow step (even if marked as always read-only) and that step is saved (any action except Cancel).

  • Since the field is not assigned until it is saved, we recommend that you make it a hidden field on the first step of a workflow. Once on the second step, it can then be displayed.

  • Once the auto number is generated, it cannot be changed, even if it is listed as an input attribute.

Limitations

Autonumber Mask

The “mask” for the Autonumber controls the pattern of values that are generated.

  • Must include a "#" symbol, which is a placeholder for a sequential number;

  • Can force leading zeros by including them prior to the "#" symbol;

  • Can include any constant character string, such as "MIP";

Example: If the mask is “MIP000#A”, then the first number generated would be “MIP0001A”, then “MIP0002A”, and so forth.

The mask supports other placeholders as well:

Category

Placeholder

Value

Category

Placeholder

Value

Date

$D

Full day name

$d

Short day name

#D

Long day number

#d

Short day number

$M

Long month name

$m

Short month name

#M

Long month number

#m

Short month number

#Y

Long year number

#y

Short year number

Time

#H

Long hour

#h

Short hour

#I

Long minute

#i

Short minute

#S

Long second

#s

Short second

#T

Long time string

#t

Short time string

Other

##

Literal “#” character

$$

Literal “$” character

Autonumber Seed

The “seed” is controls the sequential value part of the Autonumber. It represents the last used value in the sequence.

Example: If the mask is “MIP000#A”, and the most recently generated value is “MIP0022A”, then the seed value is “22”.

The seed value is incremented prior to generating a new value.