SQLite

Check-in [fa06a6fed9]
Login

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

Overview
Comment:Add the ability to use indices for the first few terms of an ORDER BY clause, then sort in batches to handle the later terms.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: fa06a6fed9f48322d9b89721799ba12c46efa898
User & Date: drh 2014-03-21 20:58:42.176
Context
2014-03-22
00:27
Fix the ORDER BY optimization logic so that it will do a block-sort on a partial DESC ORDER BY. This enhancement uncovered a memory leak in pushUntoSorter() which is also fixed. (check-in: c36f74611c user: drh tags: trunk)
2014-03-21
20:58
Add the ability to use indices for the first few terms of an ORDER BY clause, then sort in batches to handle the later terms. (check-in: fa06a6fed9 user: drh tags: trunk)
19:56
Change the names of SRT_DistTable and SRT_Table used by CTE to more meaningful SRT_DistFifo and SRT_Fifo, respectively. Simplify the IgnorableOrderby() macro in the process. (check-in: 45d8cc678d user: drh tags: trunk)
18:45
Merge the OFFSET-on-query-without-FROM fix from trunk. (check-in: 71e9ae72c2 user: drh tags: orderby-planning)
Changes
Unified Diff Side-by-Side Diff Patch
Changes to src/btree.c.
Changes to src/btree.h.
Changes to src/expr.c.
Changes to src/pragma.c.
Changes to src/select.c.
Changes to src/sqliteInt.h.
Changes to src/vdbe.c.
Changes to src/vdbeInt.h.
Changes to src/vdbeaux.c.
Changes to src/vdbesort.c.
Changes to src/where.c.
Changes to src/whereInt.h.
Changes to test/distinct.test.
Changes to test/orderby5.test.
Added test/orderby6.test.
Changes to test/whereG.test.