Data templates and transformations > Passing external parameters

Passing external parameters
To be able to use external parameters (e.g. global StreamServe variables) in transformations, these parameters must be passed on to the transformation process as tdt.param transformation parameters. The value of a transformation parameter is an XPath expression that references available Message data and global StreamServe variables.
To define a transformation parameter
1
Select File > Processing Properties and click Custom Properties.
2
Enter tdt.param:name as Name and the appropriate XPath expression as Value and click OK.
To reference tdt.param:name in a transformation rule you use $name. For example, to reference tdt.param:fullname you use $fullname.
Example 20
tdt.param:fullname = concat(/data/message/FirstName, ' ', /data/message/LastName)
 
Example 21
tdt.param:fullname = concat($name, ' ', $surname)
 
Example 22
In this example the variables are string variables, and($varname) is used to make sure the parameter is evaluated as a string.
tdt.param:name = ($name)
tdt.param:surname = ($surname)
tdt.param:lang = ($Language)
 
Defining a parameter more than once
If you, by mistake or for some other reason, define a parameter with the same name more than once, the result will not be what is expected.
For example, you might define the following:
tdt.param:name = ($name)
tdt.param:name = ($surname)
In this case the first entry is used and the second is discarded.
OpenText StreamServe 5.6.2 Updated: 2018-01-26