The Random field generates a random string once per record, drawn from the character sets you turn on. The value is generated for you, so submitters never type it.
When to use it
Reach for Random when you want an unpredictable token on each record:- Access codes, opaque references, or sample identifiers.
- A short random segment to fold into a Concatenation field.
- A value where a sequential number would be too easy to guess and a Terminus ID’s fixed shape is not what you want.
How it works
The first time you submit a record, the field generates a string oflength characters using the character sets you enabled, then keeps that value for the life of the record. It is not re-rolled when you edit or re-save the record later.
You choose which character sets to draw from. At least one of the three must be on.
Settings reference
| Setting | Required | Default | Description |
|---|---|---|---|
length | Yes | None | Number of characters to generate, from 1 to 50. |
include_numbers | Yes | None | Include digits 0-9. |
include_lowercase | Yes | None | Include lowercase letters a-z. |
include_uppercase | Yes | None | Include uppercase letters A-Z. |
include_numbers, include_lowercase, and include_uppercase must be true.
Example
Anaccess_code field on a Passes taxonomy:
K7P2QXM9: eight characters of uppercase letters and digits. That value is generated once, when you first submit the record, and stays the same from then on.
Gotchas
- The value is stable, not regenerated. It is produced once at first submission and kept afterward. Editing the record later does not change it.
- Random is not unique. There is no collision check across records, so two records can in principle land on the same string. For uniqueness, use Terminus ID or Auto Number.
- Enable at least one character set. With all three off, the field has no characters to draw from.
- Short strings collide more often. The shorter the
lengthand the fewer the enabled sets, the higher the chance of a repeat. - It is read-only. The value is generated for you and cannot be set or edited in the submission form.
Related
- Fields
- Auto Number field: sequential, guaranteed-distinct numbers.
- Terminus ID field: a system-unique identifier.
- Other computed fields