Helen Borrie <hele...@iinet.net.au> wrote Wed, 27 Apr 2016 03:17:00 +0300:

Hello, Helen

I would like to say a few errors in the description of Operator Precedence.

Common Language Elements->Expressions->SQL Operators->Operator Precedence

1. Arithmetic Operators. Among the arithmetic operators of places without  
unary plus (+) and minus (-). They have a higher priority than  
multiplication and division.

Operator   Purpose     Precedence
----------------------------------
   +       Unary plus      1
   -       Unary minus     1
   *       Multiplication  2
   /       Division        2
   +       Addition        3
   -       Subtraction     3

2. Comparison Operators. All comparison operators have the same priority.  
Since Firebird 3.0.1. predicate IS has a higher priority than the other  
comparison operators. The Firebird 2.x predicate IS has the same priority  
as other comparison operators.

Operators Priorities can be found in parse.y

// precedence declarations for expression evaluation
%left   OR
%left   AND
%left   NOT
%left   '=' '<' '>' BETWEEN LIKE CONTAINING STARTING SIMILAR KW_IN NEQ GEQ  
LEQ NOT_GTR NOT_LSS
%left   IS
%left   '+' '-'
%left   '*' '/'
%left   UMINUS UPLUS
%left   CONCATENATE
%left   COLLATE

-- 
Cheers,
Simonov Denis

------------------------------------------------------------------------------
Mobile security can be enabling, not merely restricting. Employees who
bring their own devices (BYOD) to work are irked by the imposition of MDM
restrictions. Mobile Device Manager Plus allows you to control only the
apps on BYO-devices by containerizing them, leaving personal data untouched!
https://ad.doubleclick.net/ddm/clk/304595813;131938128;j
_______________________________________________
Firebird-docs mailing list
Firebird-docs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/firebird-docs

Reply via email to