User Guide > Data Generation Techniques and Parameters > Advanced Generation
  

Advanced Generation

An advanced generation rule is a combination of generation techniques that generates test data in target columns based on the configuration of one or more than one input port, variable port, and output port.
You can generate test data for string, numeric, and date data types. In an advanced rule, create input columns, variable columns, and output columns based on the test data requirements. Configure a generation rule for a variable column, and add an expression for the output column.
The following image shows the advanced generation rule parameters that you configure:
The New Generation Rule dialog box shows the input, variable, and output columns of an advanced rule. The var variable column is selected and the general properties and generation rule set parameters are displayed.

Advanced Generation Example

You want to generate email IDs for the employees in EMAIL_ID column in the EMPLOYEE table. Create an input port in_FirstName of string data type. Create a variable port var_Domain of string data type. Configure the Generation Rule Set technique for the variable port. Configure two rules to generate yahoo and gmail domain names. Create an output port out_Email to concatenate the input name and the variable domain with the following expression:
CONCAT(CONCAT(in_FirstName,'@'),var_Domain)
Assign the rule to the EMAIL_ID column, and generate and run the workflow to produce the output email IDs.
The following table shows a sample output:
First_Name
EMAIL_ID
Richmond
Richmond@gmail.com
Debora
Debora@gmail.com
Shaniah
Shaniah@yahoo.com
Lena
Lena@yahoo.com

Advanced Generation Parameters

Configure parameters for each column that you create in an advanced generation rule.
The following table describes the general properties that you can configure for input, output, and variable columns:
Parameter
Description
Column Name
The name of an input, output, or variable column. Enter a name. The name does not have to match the name of a column in the source. When you assign the rule to the target metadata in a project, you map the column names in the rule to column names in the database.
Column Type
The column type. You can configure the following types of columns:
  • - Input. Receives the target metadata.
  • - Variable. A temporary column that contains intermediate values. You can apply generation rules to variable column values in order to mask data before returning data to output columns.
  • - Output. Returns the output data. You can apply an expression to a variable column and return the data in the output column.
Datatype
The data type of the column. Select string, numeric, or date data type.
Precision
The precision for the column. The maximum number of digits or the maximum number of characters that the column can accommodate. For example, 798.650 has a precision of 6.
Scale
Number of digits to the right of the decimal point in a number.
The following table describes the properties that you can configure for input columns:
Parameter
Description
Parameterize Input Port
Optional. Use a parameter value for the input column. You do not need to map the input port to a column if the you parameterize the input port.
Parameter Name
The name of the parameter that you can use for the input column. Required if you choose to parameterize the input port.
The following table describes the masking properties that you can configure for variable columns:
Parameter
Description
Dependency
Optional. Select a variable port as a dependent port for another variable port. When you create a second variable port, you can see the first variable port in the drop-down list.
Generation Technique
Applies a generation rule to the input column and writes the results in the variable column. You can create multiple variable columns and configure rules.
You can select the following techniques:
  • - Conditional. Generates string data with a condition. Specify a conditional expression based on which you can generate test data in a target column. Select a generation rule that you can apply to the target column based on the specified condition.
  • - Generation Rule Set. The data generation rule to apply to the input column. Specify a distribution percentage. You can group the records based on a foreign key.
The following table describes the properties that you can configure for output columns:
Parameter
Description
Expression
Required. An expression to apply to input and variable columns to generate an output. You can create the expression in the Expression Builder.