Is there a way to build a lookup table, or maybe build a COPY command within an xlate, such that if Cloverleaf doesn’t find a match within the table, it will send across a constant?
I use lookup tables this way regularly. I define my default to some thing like NONE, pass the result of the lookup into a temporary value and then check this using an IF statement. I then COPY the relevant value based upon the result of the IF.
The default value worked fine. Another lookup table question, have either of you tried entering a lookup value with a wild card. In other words, REGENCE@, would catch REGENCE PPO, REGENCE PRIMARY CARE,etc?
If you can load the table on the fly and convert it into 2 lists, 1 for input and 2nd for output. You could then search either side of the list using a wildcard and then reference the matching element in the other list.
I’ve done the first part, but haven’t had any need for a wildcard lookup in a table.
Steve, interesting idea. Could you provide a skeleton proc on how you are proposing to do this. I am a Cloverleaf newbie, so please bear with. How would you insert this into the xlate? The data I am pointing at the table is coming from a VRL file, and I thought about running it through a proc before it hits the table with some IF statements that would take similar inputs, and send out a standard output. This table is for insurance company names, and there are lots of similar, but slightly different names.