Skip to main content


Enable/disable ANSI SQL operator precedence system-wide.


[SQL]    ANSIPrecedence=n


The value n may be 1 or 0:

  • When 1 (true), InterSystems SQL gives the “*”, “\”, “/”, and “#” arithmetic operators higher precedence than the “+”, “-”, and “||” operators. Operators with higher precedence are executed before operators with lower precedence.

  • When 0 (false), InterSystems SQL executes arithmetic expressions in strict left-to-right order. This matches the convention used in ObjectScript.

You can use parentheses to enforce the desired precedence.



Range of Values

0 or 1. The default is 0

Management Portal

On the page System Administration > Configuration > SQL and Object Settings > General SQL Settings, for the Apply ANSI Operator Precedence setting, choose Yes (true) or No (false).

FeedbackOpens in a new tab