Hello, I have OpenLAB CDS 2.6 and have a question regarding the Expression Editor in the Report Template Editor (RTE).
My question is how I can setup an IF statement for partial text. For example, I have 6 varying ways the B1 units can be expressed as (mg/serving, mg/tablet, and mg/cap; and the equivalent in mcg).
Background:
I can setup a basic IF statement using this basic structure, =IF(CFE (Sample_CustomFields,"B1 units") ="mg/serving", IF(CFE (Sample_CustomFields,"B1 units") ="mg/cap"... but then I have to repeat the IF statement 6 times. Thus, I was wondering if there was a way to perform an IF statement in the RTE using partial text like in Excel:
=IF(COUNTIF(A2,"*mg*"),"Value if true","Value if false")
If there is, could I get assistance with the appropriate syntax if this is possible?