FuuzHelp Center

Administer · App Management

Sequences

Last updated December 27, 2025, 5:36 PM UTC · fuuz.com/help/sequences

Sequences

Article Type: Concept
Audience: App Administrators, Application Designers, Developers
Module: App Management
Applies to Versions: All Versions

1. Overview

Sequences provide system-generated unique identifiers for data records using configurable patterns including prefixes, suffixes, increments, and zero-padding. This feature eliminates manual code development for common numbering scenarios such as work orders, purchase orders, sales orders, serial numbers, lot numbers, and process routing steps. Sequences integrate directly with data model schemas as default field values and can be referenced in flows, imports, and integrations, ensuring consistent and automatic number generation across the entire application.

Note: Sequences are system-defined and managed through the Sequences screen. They support both String and Integer types, with String sequences offering additional prefix and suffix configuration. Sequences can be configured with unique constraints per data model relation, enabling scenarios like starting a new sequence for each product ID in process routings (10, 20, 30 per product).

2. Architecture & Data Flow

Definitions

Components

Sequence Generation Process

When a sequence is invoked (via data model default value, flow action, or import):

  1. System determines if unique constraint applies (checks for key value from related data)
  2. Retrieves current sequence value for the applicable key (or default if no key)
  3. Increments value by configured increment amount
  4. Applies zero-padding to meet minimum digit requirements
  5. For String type: prepends prefix and appends suffix to create final value
  6. Stores updated sequence value in Sequence Numbers tracker
  7. Returns generated value to calling context (field default, flow variable, import record)

3. Use Cases

4. Screen Details

The Sequences screen is accessed via App Management > Sequences in the App Admin menu section.

Sequences List Screen

The main screen displays all sequences with searchable and filterable columns:

Column Description
Name Unique identifier for the sequence (clickable to open detail view)
Type String or Int
Increment Numeric value by which sequence advances
Prefix String type only - characters prepended to sequence number
Suffix String type only - characters appended to sequence number
Zero Padding Min Minimum number of digits with leading zeros
Zero Padding Max Display field showing maximum digits based on current sequence values
Sequence Numbers Count of sequence number instances (shows how many keys/variations exist)

Actions (Toolbar):


Create/Edit Sequence Form

The Create/Edit dialog presents fields based on selected Type:

All Types

Field Type Description
Name Text (Required) Unique sequence identifier. Validation: "Name must be provided"
Type Select (Required) String or Int. Selection determines available fields below.
Increment Number (Required) Amount to advance sequence. Default: 1. Common values: 1, 10, 20, 100.

String Type Only

Field Type Description
Prefix Text (Optional) Characters prepended to sequence number (e.g., "WO-", "NCR-")
Suffix Text (Optional) Characters appended to sequence number (e.g., "-2025", "-REV")
Zero Padding Number (Required) Minimum digits for numeric portion. Default: 0. Example: 4 produces 0001, 0002.

Int Type Only

Int type sequences do not have Prefix or Suffix fields - only Increment and Zero Padding are configurable.




Sequence Detail Screen

Clicking a sequence name opens the detail view with three tabs:

DETAILS Tab

Shows sequence configuration fields (Name, Type, Increment, Prefix, Suffix, Zero Padding Min) with inline editing capability. Right panel displays History:

SEQUENCE DATA CHANGES Tab

Displays audit trail of changes to the sequence definition configuration, showing what changed, when, and by whom.

SEQUENCE NUMBERS Tab

Lists all sequence number instances with management capabilities:

Column Description
Id Internal identifier for the sequence number instance
Label Human-readable description (e.g., "nonConformanceReport - NCR-16")
Sequence Clickable link to parent sequence definition
Key Unique constraint value (e.g., productId) triggering separate sequence. Empty if no unique constraint.
Value Current sequence value (e.g., "NCR-16")

Actions (SEQUENCE NUMBERS Tab):




5. Technical Details

Type Options: String vs Int

String Type

Int Type

Important: The sequence Type must match the data model field type. Assigning a String-type sequence to an Int field (or vice versa) will cause errors. Verify data type compatibility when configuring sequences as field default values.

Integration with Data Models

Sequences integrate with data model schemas as default field values, providing automatic number generation during record creation:

Configuration Steps

  1. Navigate to Data Management > Data Model > Custom Fields
  2. Select the data model (e.g., WorkOrder, NonConformanceReport)
  3. Create or edit a field (ensure field type matches sequence type)
  4. In field configuration, locate Default Value section
  5. Select the desired sequence from dropdown (only matching-type sequences appear)
  6. Save field configuration

Behavior

Integration with Flows

Sequences can be invoked within data flows for dynamic number generation:

Unique Constraints and Multi-Key Sequences

Sequences support unique constraints that trigger separate sequence generation based on related data model keys. This powerful feature prevents writing massive amounts of manual code for context-specific numbering.

How It Works

  1. Configure unique constraint on data model field that references another model (e.g., productId relation)
  2. Assign sequence to field as default value
  3. When record created, system checks value of constraint key (e.g., which productId)
  4. System creates or retrieves separate sequence instance for that specific key
  5. Each key maintains its own independent sequence counter

Common Example: Process Routing Steps

Scenario: Each product has its own routing with steps numbered 10, 20, 30, 40...

Configuration:

Result:

Each product ID triggers a new sequence instance, visible in the SEQUENCE NUMBERS tab with Key column showing the productId value.

Import and Integration Support

Important: This sequence feature is for Fuuz system-generated sequences only. For instances where you need to use a series generated by another external system (customer-provided lot numbers, EDI sequences, etc.), you're better off creating a custom data model table in Fuuz to house those numbers. Custom tables provide simple import functionality and you can still use them easily in flows and screens.

Naming Conventions

Naming conventions depend on the use case and help maintain organization:

Use Case Convention Example
Data Model Field dataModel_fieldName workOrder_orderNumber
Flow Generation flowName_nodeName orderProcessing_batchNumber
Functional Purpose purposeDescription nonConformanceReport

Sequence Management Operations

Set Sequence Value

Manually set the current sequence value (available in SEQUENCE NUMBERS tab):

Reset Sequence

Reset sequence counter back to 0 (available in SEQUENCE NUMBERS tab):

Permissions and Access Control

Scope and Migration

6. Resources

7. Troubleshooting

Issue Cause Resolution
Sequence not appearing in data model field default value dropdown Type mismatch - sequence Type does not match field data type Verify field is String type for String sequences or Int/Number type for Int sequences. Create new sequence with matching type or change field type if appropriate. Only compatible-type sequences appear in dropdown.
Sorting not working correctly - numbers appear out of order String type sequence without proper zero padding causes lexicographic sort String values sort alphabetically: "1", "10", "100", "2", "20". Solution: (1) Use zero padding in String sequences to force correct sort order (0001, 0010, 0100, 0002, 0020), or (2) Use Int type sequences instead which sort numerically. Screens can define sort order for Int fields but may not interpret String values as integers.
Mixed data from import and Fuuz sequences sorting incorrectly Imported sequence numbers from another system have different schema/pattern than Fuuz-generated sequences in same field Best practice: Do not mix imported sequences with Fuuz-generated sequences in the same field. Options: (1) Use separate fields for imported vs. generated values, (2) Standardize imported data to match Fuuz sequence pattern before import, (3) Use custom data model tables for externally-generated sequences instead of Fuuz Sequences feature.
Sequence generating unexpected values after migration Sequence counter not set to appropriate starting value for new environment After migrating application package to new environment, navigate to SEQUENCE NUMBERS tab for affected sequences. Use "Set Sequence Value" action to establish correct starting point. Example: If production last used PO-5432, set QA environment sequence to start at QA-appropriate value like 10000 to avoid confusion.
Test data cluttering sequence numbers Creating test records advances sequences, leaving gaps or high numbers For testing environments: (1) Delete test data records, (2) Navigate to SEQUENCE NUMBERS tab, (3) Use "Reset Sequence" action to set counter back to 0, (4) Begin testing with clean sequence. Do NOT use Reset in production environments as it can create duplicate values.
Unique constraint sequences not creating separate instances Unique constraint not configured correctly on data model field Verify data model field has unique constraint properly configured referencing the relation field (e.g., productId). Check that relation field is populated when records are created - sequences cannot create separate instances if constraint key value is null. Review SEQUENCE NUMBERS tab to confirm multiple instances with different Key values exist.
Cannot find sequence in Flow Designer Sequence not yet created or incorrect reference syntax Verify sequence exists in Sequences screen. In flows, use appropriate sequence generation function or node with exact sequence name. Consult flow documentation for correct syntax to invoke sequences.
Duplicate sequence values appearing Manual overrides or reset operation created duplicates, or concurrent generation race condition If users can manually override sequence values, consider adding data model unique constraint on field to prevent duplicates. If duplicates occur after reset operation, use Set Sequence Value to jump past existing values. For concurrency issues, contact Fuuz support to investigate sequence generation locking mechanism.
Need to use customer-provided lot numbers or EDI sequences Fuuz Sequences feature is for system-generated values, not external sequence management For sequences generated by external systems: (1) Create custom data model table to house external sequence numbers, (2) Provide simple import functionality to load external sequences, (3) Reference custom table in flows and screens. This approach gives you full control over external numbering schemas and import/update patterns.
Zero padding not applying correctly Zero Padding Min value set to 0 or incorrect configuration Edit sequence and set Zero Padding Min to desired digit count (e.g., 4 for "0001"). Note that zero padding applies to numeric portion only - prefix and suffix are added as-is. Verify example values in SEQUENCE NUMBERS tab match expected format after configuration change.
Import not assigning sequence values automatically Import configuration set to use provided values rather than generate sequences During import setup, verify option to "Generate sequence values" or "Use default values" is selected for fields with sequence defaults. If importing explicit values, leave field empty in CSV to trigger sequence generation.

Best Practices

8. Revision History

Version Date Editor Description
1.0 2024-12-27 Craig Scott Initial Release