This site uses different types of cookies, including analytics and functional cookies (its own and from other sites). To change your cookie settings or find out more, click here. If you continue browsing our website, you accept these cookies.
What's the proper syntax for this statement......IF [Quarter] = "Q1" THEN ToNumber[% of FY]* [PYABA] ELSE " " ENDIF
Te [% of FY] field is a v_string data type....
I would just change the Else. Since this is set up to be a number based on what I see, but the Else would be a string. Also missing the () around the tonumber()
Options (changes in bold):
Make it a string
IF [Quarter] = "Q1" THEN tostring(ToNumber([% of FY])* [PYABA]) ELSE " " ENDIF
As a number
IF [Quarter] = "Q1" THEN ToNumber([% of FY])* [PYABA] ELSE 0 ENDIF
or if you don't want zeros you can use nulls
IF [Quarter] = "Q1" THEN ToNumber([% of FY])* [PYABA] ELSE null() ENDIF
The final option is to just change the [% of FY] to a number with the Select tool before the Formula.
Hope this helps.