I have an XML that contains string values like “Yes” or “No”.
It would simplify the code in my data mapper if it was possible to set the type of a field to Boolean and it would automatically recognize values like:
Yes, No, True, False (not case sensitive)
At the moment this only works with 0 and 1 where it translates properly to a true or false value.
let myvar = data.extract(’./xpath’);
if (myvar && (myvar.toUpperCase() == “YES” || myvar.toUpperCase() == “TRUE”)) true; else false;