Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Syntax error in SharePoint calculated column formula

Is it possible to debug SharePoint calculated column formulas?

I am trying with a really simple SharePoint calculated formula =IF([YTD]<[Budget], "OK", "Not OK"). This being a Danish installations of SharePoint I believe the fomula should look like this:

=HVIS([YTD]<=[Budget]; "OK"; "Not OK")

But this just leaves with the same syntax error or not supported error. I have tried all combinations of IF/HVIS, with/without the square brackets, comma/semicolon, single quotes/double quotes, but nothing works. The formula =YTD<=Budget works.

like image 868
Jan Aagaard Avatar asked Aug 19 '26 07:08

Jan Aagaard


1 Answers

The correct formular depends on how "danish" the installation is :-(

If the language used to create the site with the list is danish then you need to use "HVIS" instead of "IF"

If the regional setting is danish then you need to use ";" as the seperator instead of "," because "," is used as decimal point.

So possible formulars are:

=HVIS([YTD]<=[Budget]; "OK"; "Not OK")
=IF([YTD]<=[Budget]; "OK"; "Not OK")
=HVIS([YTD]<=[Budget], "OK", "Not OK")
=IF([YTD]<=[Budget], "OK", "Not OK")
like image 129
Per Jakobsen Avatar answered Aug 20 '26 21:08

Per Jakobsen