Operators for Expressions

Visual Database Tools

Visual Database Tools

Operators for Expressions

You can use a variety of operators in constructing expressions for your query, including mathematical and text operators.

Mathematical Operators

The following table lists the mathematical operators you can use in constructing an expression.

Operator Meaning
+, - Unary positive, negative
+ Addition
- Subtraction
* Multiplication
/ Division

Note   For more information, see Operators.

If you use more than one mathematical operator in an expression, the Query Designer processes the expression according to the following operator precedence. To override the default precedence, use parentheses around the portion of the expression that is to be evaluated first. If more than one operator of the same level is included, the operators are evaluated left to right.

  1. Unary + and -

  2. * and /

  3. + and -

Text Operator

You can perform one operation on text: concatenation or the linking together of strings. To concatenate a string, use the "+" operator in the Grid pane. For more information, see Operators.

You can also use the ODBC CONCAT function, which is supported by ODBC-compliant drivers. For example, the following expression illustrates how you can use the CONCAT function to combine authors' last name and first name with a comma between them:

{ fn CONCAT(au_lname,{ fn CONCAT (', ', au_fname)})}

For more details about functions you can use, see Functions for Expressions.

See Also

Reference