Using xlateInVals and xlateOutVals

xlateInVals is the list variable Tcl that is used to store the values from the source side of the xlate statement.

xlateOutVals is the list variable Tcl that is used to store the values from the destination side of the xlate statement.

Note:  These variables are list objects and not strings.

This example converts an address to all uppercase letters in an xlate.

In Tcl:

lappend xlateInVals "1111 Chapel Hill Rd."
set xlateOutVals [string toupper [lindex $xlateInVals 0]]
puts [lindex $xlateOutVals 0] ;# Returns "1111" not "1111 CHAPEL HILL RD."
set tmp [string toupper [lindex $xlateInVals 0]]
set xlateOutVals [list $tmp]
puts [lindex $xlateOutVals 0] ;# Returns "1111 CHAPEL HILL RD."

The first puts statements returns only "1111". The second puts statement returns the entire address because xlateOutVals is treated similar to a list.

This is added to the Translation Configurator's Action pane:

BULKCOPY
COPY: {0(0).PID(0).#11(0).(0) -> 0(0).PID(0).#11(0).(0)}
COPY: {0(0).PID(0).#19(0).(0) -> 0(0).PID(0).#19(0).(0)}

In this example, xlateOutVals is not treated as a list in the Pre Proc pane.

set tmp [string toupper [index $xlateInVals 0]] 

The result is 1111 in PID.11.

{0(0).PID(0).#11(0).(0) :  >1111^^COLUMBIA^MO^65203

You can also treat xlateOutVals as a list.

set tmp [string toupper [index $xlateInVals 0]]
set xlateOutVals [list $tmp]
The result is 1111 CHAPEL HILL RD. in PID.11.
{0(0).PID(0).#11(0).(0)  :  >1111 CHAPEL HILL RD.^^COLUMBIA^MO^65203