You are on page 1of 4

NiC IT Academy

nicitacademy@gmail.com

Parameter and Variable:


In the Informatica powerenter designer, use mapping parameters and variables to make
mappings more flexible. Mapping parameters and variables represent values in mappings
and mapplets. If we declare mapping parameters and variables in a mapping, we can reuse
a mapping by altering the parameter and variable values of the mapping in the session

A parameter file can contain different types of parameters and variables. When we run a
session or workflow that uses a parameter file, the Integration Service reads the parameter
file and expands the parameters and variables defined in the file.

This can reduce the overhead of creating multiple mappings when only certain attributes of
a mapping need to be changed.When we use a mapping parameter or variable in a
mapping, first we declare the mapping parameter or variable for use in each mapplet or
mapping. Then, we define a value for the mapping parameter or variable before we run the
session.

Use mapping parameters and variables in a mapping to incrementally extract data. Use
mapping parameters or variables in the source filter of a Source Qualifier transformation to
determine the beginning timestamp and end timestamp for incrementally extracting data.

We can configure system parameters or user-defined parameters.

System parameters:

Built-in parameters for a Data Integration Service. System parameters define the
directories where the Data Integration Service stores log files, cache files, reject
files, source files, target files, and temporary files. An administrator defines the
system parameter default values for a Data Integration Service in the Administrator
tool.

User-defined parameters:

Parameters that we define in transformations, logical data objects, mappings, and


workflows. Create user-defined parameters to rerun a mapping with different
connection, flat file, cache file, temporary file, expression, ports, or reference table
values.
NiC IT Academy
nicitacademy@gmail.com
We can define the following types of parameter and variable in a parameter file:
 Service variables.
Define general properties for the Integration Service such as email addresses, log file counts,
and error thresholds. $PMSuccessEmailUser, $PMSessionLogCount, and
$PMSessionErrorThreshold are examples of service variables. The service variable values we
define in the parameter file override the values that are set in the Administrator tool.
 Service process variables.
Define the directories for Integration Service files for each Integration Service process.
$PMRootDir, $PMSessionLogDir, and $PMBadFileDir are examples of service process variables.
The service process variable values we define in the parameter file override the values that are
set in the Administrator tool. If the Integration Service uses operating system profiles, the
operating system user specified in the operating system profile must have access to the
directories we define for the service process variables.
 Workflow variables.
Evaluate task conditions and record information in a workflow. For example, we can use a
workflow variable in a Decision task to determine whether the previous task ran properly. In a
workflow, $TaskName.PrevTaskStatus is a predefined workflow variable and $$VariableName is
a user-defined workflow variable.
 Worklet variables
. Evaluate task conditions and record information in a worklet. We can use predefined worklet
variables in a parent workflow, but we cannot use workflow variables from the parent workflow in
a worklet. In a worklet, $TaskName.PrevTaskStatus is a predefined worklet variable and $$
VariableName is a user-defined worklet variable.
 Session parameters.
Define values that can change from session to session, such as database connections or file
names. $PMSessionLogFile and $ParamName are user-defined session parameters.
 Mapping parameters.
Define values that remain constant throughout a session, such as state sales tax rates. When
declared in a mapping or mapplet, $$ParameterName is a user-defined mapping parameter.
 Mapping variables.
Define values that can change during a session. The Integration Service saves the value of a
mapping variable to the repository at the end of each successful session run and uses that value
the next time we run the session. When declared in a mapping or mapplet, $$
VariableName is a mapping variable.

We cannot define the following types of variables in a parameter file:

 $Source and $Target connection variables.


Define the database location for a relational source, relational target, lookup table, or stored
procedure.
 Email variables.
Define session information in an email message such as the number of rows loaded, the session
completion time, and read and write statistics.
 Local variables.
Temporarily store data in variable ports in Aggregator, Expression, and Rank transformations.
NiC IT Academy
nicitacademy@gmail.com

 Built-in variables.
Variables that return run-time or system information, such as Integration Service name or system
date.
 Transaction control variables.
Define conditions to commit or rollback transactions during the processing of database rows.
 ABAP program variables.
Represent SAP structures, fields in SAP structures, or values in the ABAP program.

Heading Scope

[Global] All Integration Services, Integration Service processes,


workflows, worklets, and sessions.
[Service:service name] The named Integration Service and workflows, worklets, and
sessions that this service runs.
[Service:service name.ND:node name] The named Integration Service process and workflows,
worklets, and sessions that this service process runs.
[folder name.WF:workflow name] The named workflow and all sessions within the workflow.
[folder name.WF:workflow name.WT:worklet The named worklet and all sessions within the worklet.
name]
[folder name.WF:workflow name.WT:worklet The nested worklet and all sessions within the nested
name.WT:worklet name...] worklet.
[folder name.WF:workflow name.ST:session
name]
-or-
[folder name.WF:workflow name.WT:worklet
name.ST:session name]
-or-
[folder name.session name]
-or-
[session name]
NiC IT Academy
nicitacademy@gmail.com

Sample Parameter File


The following text is an excerpt from a parameter file that contains service variables for one
Integration Service and parameters for four workflows:

----------------------------------------

File created by NiC IT Academy 11/12/2021

----------------------------------------

[Service: IntService_Dev_01]

$PMSuccessEmailUser=pcadmin@mail.com

$PMFailureEmailUser=pcadmin@mail.com

[HET_TGTS.WF:wf_TCOMMIT_INST_ALIAS]

$$platform=unix

[HET_TGTS.WF:wf_TGTS_ASC_ORDR.ST:s_TGTS_ASC_ORDR]

$$platform=unix

$DBConnection_ora=Ora2

$ParamAscOrderOverride=UPDATE T_SALES SET CUST_NAME = :TU.CUST_NAME, DATE_


SHIPPED = :TU.DATE_SHIPPED, TOTAL_SALES = :TU.TOTAL_SALES WHERE CUST_ID =
:TU.CUST_ID

[ORDERS.WF:wf_PARAM_FILE.WT:WL_PARAM_Lvl_1]

$$DT_WL_lvl_1=02/01/2021 01:05:11

$$Double_WL_lvl_1=2.2

[ORDERS.WF:wf_PARAM_FILE.WT:WL_PARAM_Lvl_1.WT:NWL_PARAM_Lvl_2]

$$DT_WL_lvl_2=03/01/2021 01:01:01

$$Int_WL_lvl_2=3

$$String_WL_lvl_2=aaa

You might also like