What am I doing wrong?
I added this line to Chart Document Header -
{if match(LOC.ABBREVNAME,"PTN")0 THEN "Physical Therapy North" ELSE "Sports Medicine North" ENDIF}
And I am getting this error:
<-COMPILER ERROR NEARBY: Expect COMMA OR RIGHT PARENTHESIS. Instead had IDENTIFIER after IDENTIFIER
Please help.
TIA
Try this:
{if match(LOC.ABBREVNAME,1,”PTN”)>0 THEN “Physical Therapy North” ELSE “Sports Medicine North” ENDIF}
You were missing the middle parameter for match which tells the function where to start looking in the string. Also, you needed a logical operator to get your if statement to return true or false. Looking at your statement I'm thinking you want a greater than sign. Since the match will return a number greater than 1 if it finds your value of "PTN". Hopefully this helps.
Missing comparator only, start value is optional, suggest replace ")0" with ")<>0"