These generators calculate values based on a script, formula, or on other values in the database.
For details about each generator and how to configure them in the application, go to Calculated or related values in the generator reference.
AI
Generates data values based on a prompt that you provide.
{
"name": string,
"data_type": string,
"generator": "AI",
// Generator-specific fields
"ai_prompt": string, //AI prompt to use to populate the column
// End generator-specific fields
"group_key": string,
"percent_null": integer,
"virtual": boolean,
// Advanced options
"primary_key": boolean,
"index": boolean,
"seed": string,
"postprocessing_sql": string
}
Character Sequence
Populates a column with a value that uses a specific pattern. The pattern can include both random characters of a specific type and specific characters.
{
"name": string,
"data_type": string,
"generator": "Character Sequence",
// Generator-specific fields
"character_sequence": string, // The pattern to use for the values.
// End generator-specific fields
"percent_null": integer,
"virtual": boolean,
// Advanced options
"primary_key": boolean,
"index": boolean,
"seed": string,
"postprocessing_sql": string
}
Column From Another Table
Populates the column with values from a column in a different table.
{
"name": string,
"data_type": string,
"generator": "Column From Another Table",
// Generator-specific fields
"primary_key_entity": string, // Source table
"primary_key_field": string, // Source column
"enable_where": boolean, // Select values based on criteria
"foreign_key_field": string, // Other table column for criteria
"value_field": string, // Current table column value for criteria
// End generator-specific fields
"group_key": string,
"percent_null": integer,
"virtual": boolean,
// Advanced options
"primary_key": boolean,
"index": boolean,
"seed": string,
"postprocessing_sql": string
}
Foreign Key
Makes the column a foreign key to another table.
{
"name": string,
"data_type": string,
"generator": "Foreign Key",
// Generator-specific fields
"primary_key_entity": string, // References table
"primary_key_field": string, // References column
"distribution": "none"|"fixed"|"from_column"|"burn-down"|"uniform"|"normal",
// The type of distribution to use
// None uses relative prevalence instead of cardinality
// burn-down is for Until column <= 0
// -----------------------------------------------------------------------
// None (relative prevalence)
"primary_key_cardinality_field": string, // Relative prevalence column
// -----------------------------------------------------------------------
// Fixed distribution
"exact_value": integer, // The number of times to use each row
// -----------------------------------------------------------------------
// From column distribution
"primary_key_cardinality_field": string, // Column that contains the number
// of times to use the row
// -----------------------------------------------------------------------
// Until column <= 0 distribution
"value_field": string, // Column to check the value of
// -----------------------------------------------------------------------
// Uniform distribution
"min": integer, // Minimum number of times to use each row
"max": integer, // Maximum number of times to use each row
// -----------------------------------------------------------------------
// Normal distribution
"min": integer, // Minimum number of times to use each row
"max": integer, // Maximum number of times to use each row
"mean": string, // Mean number of times to use each row
"std_dev": string, // Standard deviation
// End generator-specific fields
"percent_null": integer,
"virtual": boolean,
// Advanced options
"primary_key": boolean,
"index": boolean,
"seed": string,
"postprocessing_sql": string
}
List
Populates the column from a provided list of values. You can optionally provide a weight for each value.
{
"name": string,
"data_type": string,
"generator": "List",
// Generator-specific fields
"values": text, // List of values to use for the column.
// End generator-specific fields
"group_key": string,
"percent_null": integer,
"virtual": boolean,
// Advanced options
"primary_key": boolean,
"index": boolean,
"seed": string,
"postprocessing_sql": string
}
Rank
Assigns a rank value based on the values in 2 other columns.
{
"name": string,
"data_type": string,
"generator": "Rank",
// Generator-specific fields
"partition_by_field": string, // Partition by field
"order_by_field": string, // Order by field
// End generator-specific fields
"percent_null": integer,
"virtual": boolean,
// Advanced options
"primary_key": boolean,
"index": boolean,
"seed": string,
"postprocessing_sql": string
}
Regular Expression
Produces a value that matches a regular expression that you provide. It uses the Peri-compatible regular expression syntax.
Populates a column with the sum of column values from rows in another table. To identify the rows to include, you provide join criteria.
{
"name": string,
"data_type": string,
"generator": "Sum From Another Table",
// Generator-specific fields
"primary_key_entity": string, // The table that contains the column to sum
"value_field": string, // The column that contains the values to sum
"foreign_key_field": string, // Sum table column for the join criteria
"primary_key_field": string // Current table column for the join criteria
// End generator-specific fields
"percent_null": integer,
"virtual": boolean,
// Advanced options
"primary_key": boolean,
"index": boolean,
"seed": string,
"postprocessing_sql": string
}
Sum Of Previous Rows
Adds together the values of a specified numeric column in rows that are before the current row.
{
"name": string,
"data_type": string,
"generator": "Sum Of Previous Rows",
// Generator-specific fields
"value_field": string, // Column to sum
"partition_by_field": string, // Group by
"order_by_field": string, // Order by
// End generator-specific fields
"percent_null": integer,
"virtual": boolean,
// Advanced options
"primary_key": boolean,
"index": boolean,
"seed": string,
"postprocessing_sql": string
}
Value From Previous Row
Populates a column with a value or values from another column in the previous row or rows.
{
"name": string,
"data_type": string,
"generator": "Value From Previous Row",
// Generator-specific fields
"value_field": string, // The column to get the value from
"concat_type": "single"|"list"|"json", // How many previous values to retrieve
"partition_by_field": string, // Partition by field
"order_by_field": string, // Order by field
// End generator-specific fields
"percent_null": integer,
"virtual": boolean,
// Advanced options
"primary_key": boolean,
"index": boolean,
"seed": string,
"postprocessing_sql": string
}