Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello everyone,
I'm trying to use StringHandling.UPCASE() in tmap to convert the first letter in a sentence to Capital. So here is what I tried
First expression
StringHandling.UPCASE(Var.var1)
var1 is..... StringHandling.LEFT(row1.Design,1)
Second expression
StringHandling.UPCASE(StringHandling.LEFT(row1.Design,1))
Third expression
I even tried to upper case all the sentence (to check if it works) using StringHandling.UPCASE(row1.Design)
But in all three cases I get the same error again and again, am not sure what is wrong in my syntex...
Error: Type mismatch: cannot convert from String to Boolean in tMap
Thank you for your help,
srashad
Do you have any Column as Boolean in Variable expression or Output Expression window.
Check there if you are using String instead of Boolean.
Note that : "true"(String) is not equal to true (Boolean)
Also you could use simple expression like
row1.columnname == null ? "" : row1.columnname.substring(0, 1).toUpperCase() + row1.columnname.substring(1)