Developer Workflow Guide > Mapping Task > Mapping Task Input
  

Mapping Task Input

Mapping task input is the data that passes into a Mapping task. A Mapping task can receive input data from mapping parameters or from Mapping task configuration properties.
Assign values to Mapping task input on the Mapping task Input tab.
The following image shows the Mapping task Input tab:
The Mapping task Input tab shows the Parameter Inputs and Mapping Task Configuration Properties in the left column. The right column contains values for the inputs.
You can assign values to the following types of Mapping task inputs:
Mapping Parameter Inputs
Mapping parameters are parameters that you define at the mapping level. The Input tab lists all the parameters for a mapping, including the parameters that you did not assign to a field in the mapping.
Mapping task configuration properties
Mapping task configuration properties are properties that you configure on the Advanced tab. When you need to assign a parameter to a Mapping task configuration property, you can select the Assign to Task Input option for the property. When you choose this option, the configuration property appears on the Input tab. You can then assign a value to it.
To assign a value to Mapping task inputs, click the Value column for a parameter or configuration property. A list of the mapping outputs, workflow variables, and parameters appears. You can select an output, variable, or parameter from the list, or you can create a new value.

Mapping Parameters and Mapping Tasks

The Data Integration Service can use user-defined mapping parameter values when it runs a mapping within a workflow. You can use a parameter set or a parameter file for the workflow.
When you run a workflow, you can specify a parameter set at run time. The parameter set contains user-defined parameter values. You must add a parameter set to the application when you deploy the workflow. You can include multiple parameter sets when you deploy the workflow and run the workflow with a different parameter set for each run.
You can also add a parameter set to a Mapping task. When you add a parameter set to a Mapping task, the parameter set overrides the mapping parameter values or the workflow parameter values that you defined.
When you run a workflow, you can specify a single parameter file for the workflow. You define user-defined mapping parameter values within a mapping or mapplet element in the parameter file. Define workflow parameter values within a workflow element in the parameter file.
When you run the workflow with a parameter file or a parameter set, the Data Integration Service applies all the user-defined mapping parameter values and workflow parameter values.

Override Mapping Parameters During a Workflow Run

You can override user-defined mapping parameter values during a workflow run by assigning user-defined mapping parameters to workflow parameters or variables in the Mapping task Input tab.
You cannot assign system mapping parameters used in the mapping to workflow parameters. If the mapping has a user-defined mapping parameter assigned to a flat file directory field, cache file directory field, or temporary file directory field, then you can assign the user-defined mapping parameter to a workflow string parameter.
You might want to override user-defined mapping parameter values for the following reasons:
Use run-time data for the user-defined mapping parameter value.
Assign a user-defined mapping parameter to a workflow variable when you want to use workflow run-time data for the parameter value. For example, use a workflow string variable to override a mapping string parameter that defines a flat file name. Use an Exclusive gateway to evaluate a condition and then run Assignment task A or Assignment task B. Assignment task A sets the workflow variable to FlatFileA.txt. Assignment task B sets the workflow variable to FlatFileB.txt. In the Mapping task input, assign the workflow variable to the mapping string parameter. When the Mapping task runs the mapping, the mapping uses the value dynamically assigned to the workflow variable for the source file name.
Assign distinct values to a user-defined mapping parameter that is used multiple times in the workflow.
When you include multiple Mapping tasks that run the same mapping in a single workflow, assign a user-defined mapping parameter to a distinct workflow parameter for each Mapping task. Define a distinct value for each workflow parameter in a parameter file. When you run the workflow with the parameter file, the mapping run by each Mapping task uses the value of the assigned workflow parameter.
For example, a workflow includes two Mapping tasks that contain the same mapping that uses the user-defined mapping parameter SourceConnection. When the workflow runs, you want to use a different source connection for each mapping. You assign the mapping parameter SourceConnection to a distinct workflow connection parameter for each Mapping task. For MappingTask1, you assign SourceConnection to the workflow parameter WF_SourceConnection1. For MappingTask2, you assign SourceConnection to the workflow parameter WF_SourceConnection2. Assign a parameter set to Mapping task. In the parameter set, configure distinct values for the workflow parameters WF_SourceConnection1 and WF_SourceConnection2.

Parameter Usage in a Mapping Task

You can view a list of the objects in a Mapping task that use a mapping parameter.
To view the objects in a Masking task that use a mapping parameter, click Parameter Usage from the Input view of a Mapping task. The Parameter Usage dialog box shows all the mapping parameters in a Mapping task. Select a mapping parameter to view the objects that use the parameter.
The following image shows the Parameter Usage dialog box:
The Parameter Usage dialog box lists the parameters in the mapping in the left column. Select one parameter to each object that references the parameter. The right column shows the object property that the parameter is bound to.
The Parameter Usage dialog box contains the following fields:
Parameter Name
The names of the mapping parameters in the mapping.
Name
Object type and the name of the object that uses the mapping parameter.
Path
The path to the object in the repository. Includes the folder name and the mapping name.
Property/Binding
Shows which property is bound to the mapping parameter. The mapping parameter might be bound to a user-defined parameter or to a specific field. When a mapping parameter is bound to a field or to a user-defined parameter, the mapping uses the mapping parameter value instead of the other value.

Auto-Assign Mapping Input Parameter Values

You can automatically assign mapping parameters to workflow parameters or workflow variables on the Mapping task ; tab.
Choose the Auto-Assign option to generate a workflow parameter or a workflow variable to bind to a mapping parameter in one step. You can also assign mapping parameters to workflow parameters or to workflow variables that you created previously.
To auto-assign a mapping parameter, select the mapping parameter in the Input column and click Auto-Assign.
The following image shows the Auto-Assign dialog box:
" "
Choose from the following options to assign the mapping parameter to a workflow parameter or to a workflow variable:
Workflow Parameters
Assign the mapping parameter to a workflow parameter. A workflow parameter name must exist with the same name as the mapping parameter name. The Developer tool does not match the parameters by parameter type. If the workflow has no parameter to assign the mapping parameter to, you can choose to create new parameters if no match.
Create new parameters if no match
Generate a workflow parameter with the same name as the selected mapping parameter. Workflow parameters are string types or connection types. If you create a workflow parameter from a mapping parameter that is not a string or a connection type, the Developer tool creates a string workflow parameter. The Developer tool binds the string workflow parameter to the mapping parameter.
Workflow Variables
Assign the mapping parameter to a workflow variable. The workflow variable must exist and the workflow variable name must be the same as the mapping parameter name. You cannot use the Auto-Assign option to create a workflow variable.

Clear Assignments

You can clear the value assignments for a mapping input. The value assignment is the assignment of a mapping input to a workflow parameter, workflow variable, or system parameter.
To clear the value assignment for one mapping input, select the mapping parameter in the Input column. Click Clear. Confirm that you want to remove the value assignment. The Developer tool clears the value column for the mapping input you selected.
To remove all the mapping input assignments, click Clear All. Confirm that you want to remove all the mapping input value assignments. The Developer tool clears the value column for all the mapping inputs.