Using Workflow Parameters and Variables to Write to a Dynamic Target File

Using Workflow Parameters and Variables to Write to a Dynamic Target File

Step 1. Create a Flat File Data Object Parameter for the Target File Name

Step 1. Create a Flat File Data Object Parameter for the Target File Name

A mapping parameter represents a constant value that can change between mapping runs, such as connections, source file directories, or target file names. Create a user-defined parameter in the flat file data object to represent the flat file name that the data object writes to. Apply the parameter to the output file name property in the flat file data object.
  1. Open the flat file data object used as the target in the mapping.
  2. Click the
    Parameters
    view.
  3. Click
    Add
    .
    The
    Add Parameter
    dialog box appears.
  4. Enter the parameter name.
    For example, enter targetFile as the parameter name.
  5. Select
    String
    for the parameter type.
  6. Enter a default value for the parameter.
    For example, enter target.out as the default value.
  7. Click
    OK
    .
    The Developer tool adds the parameter to the list of parameters for the flat file data object.
  8. Click the
    Write
    view.
  9. Select the Input transformation to view run-time properties that the Data Integration Service uses when it writes data to the file.
    The following figure shows the Input transformation selected in the
    Write
    view:
  10. In the
    Properties
    view, click the
    Run-time
    tab.
    The following figure shows the
    Run-time
    tab:
  11. In the
    Value
    column for the
    Output file name
    property, click
    Assign Parameter
    .
    The
    Assign Parameter
    dialog box appears.
  12. Select the parameter created for the flat file data object.
    For example, select targetFile.
  13. Click
    OK
    .
    The Developer tool displays the parameter name as the value of the
    Output file name
    property.
  14. Click
    File
    Save
    .

0 COMMENTS

We’d like to hear from you!