Documentation Source Text

Check-in [568e2f047e]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:An extra sentence of clarification on explicit collating sequences on an IN operator.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 568e2f047e0e807ac2245d10d866711e8d29af38038905d67a823db1d30f8e28
User & Date: drh 2020-05-20 16:59:42
Context
2020-05-20
17:42
Documentation updates based on code review. check-in: 0bdeed702c user: drh tags: trunk
16:59
An extra sentence of clarification on explicit collating sequences on an IN operator. check-in: 568e2f047e user: drh tags: trunk
15:02
Update the change log. check-in: 18e8d6c077 user: drh tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to pages/datatype3.in.

673
674
675
676
677
678
679



680
681
682
683
684
685
686
^The expression "x BETWEEN y and z" is logically
equivalent to two comparisons "x >= y AND x <= z" and works with
respect to collating functions as if it were two separate comparisons.
^(The expression "x IN (SELECT y ...)" is handled in the same way as the
expression "x = y" for the purposes of determining the collating sequence.)^
^(The collating sequence used for expressions of the form 
"x IN (y, z, ...)" is the collating sequence of x.)^



</p>  

<p>
^Terms of the ORDER BY clause that is part of a [SELECT]
statement may be assigned a collating sequence using the 
[COLLATE operator], in which case the specified collating function is
used for sorting.







>
>
>







673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
^The expression "x BETWEEN y and z" is logically
equivalent to two comparisons "x &gt;= y AND x &lt;= z" and works with
respect to collating functions as if it were two separate comparisons.
^(The expression "x IN (SELECT y ...)" is handled in the same way as the
expression "x = y" for the purposes of determining the collating sequence.)^
^(The collating sequence used for expressions of the form 
"x IN (y, z, ...)" is the collating sequence of x.)^
If an explicit collating sequence is required on an IN operator
it should be applied to the left operand, like this: 
"x COLLATE nocase IN (y,z, ...)".
</p>  

<p>
^Terms of the ORDER BY clause that is part of a [SELECT]
statement may be assigned a collating sequence using the 
[COLLATE operator], in which case the specified collating function is
used for sorting.