Skip to content

Commit 3766e99

Browse files
committed
Add a note that AND and OR are commutative. Apparently, they are not in
certain other products.
1 parent 4c3c8c0 commit 3766e99

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

doc/src/sgml/func.sgml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!--
2-
$Header: /cvsroot/pgsql/doc/src/sgml/func.sgml,v 1.163 2003/07/31 22:17:11 tgl Exp $
2+
$Header: /cvsroot/pgsql/doc/src/sgml/func.sgml,v 1.164 2003/08/04 14:00:13 petere Exp $
33
PostgreSQL documentation
44
-->
55

@@ -162,6 +162,14 @@ PostgreSQL documentation
162162
</tgroup>
163163
</informaltable>
164164
</para>
165+
166+
<para>
167+
The operators <literal>AND</literal> and <literal>OR</literal> are
168+
commutative, that is, you can switch the left and right operand
169+
without affecting the result. But see <xref
170+
linkend="syntax-express-eval"> for more information about the
171+
order of evaluation of subexpressions.
172+
</para>
165173
</sect1>
166174

167175
<sect1 id="functions-comparison">

doc/src/sgml/syntax.sgml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!--
2-
$Header: /cvsroot/pgsql/doc/src/sgml/syntax.sgml,v 1.79 2003/06/19 23:22:40 tgl Exp $
2+
$Header: /cvsroot/pgsql/doc/src/sgml/syntax.sgml,v 1.80 2003/08/04 14:00:14 petere Exp $
33
-->
44

55
<chapter id="sql-syntax">
@@ -1216,7 +1216,7 @@ SELECT name, (SELECT max(pop) FROM cities WHERE cities.state = states.name)
12161216
</para>
12171217
</sect2>
12181218

1219-
<sect2>
1219+
<sect2 id="syntax-express-eval">
12201220
<title>Expression Evaluation</title>
12211221

12221222
<para>

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy