I have a new xlate I’m working on where ICD9 codes are coming into Cloverleaf separated by a ~. The vendor on the receiving end wants me to parse them into a DG1 segment in the ORU so I’m sending them out of our pathology system into an unused field in the OBR, field 20, and them trying to convert the ~ to a ^ so I can grab as many codes as they sent. I’ve set this field to be repeating in the variant, and inserted various tcl snipets into the COPY command, but all the xlate grabs is the first code.
set var $xlateInVals
regsub -all {~} $var “^” var1
set xlateOutVals [join $var1 “^”]
Any suggestions on how to get it to recognize the other ones?