dan [Sat, 17 Aug 2019 19:13:49 +0000 (19:13 +0000)]
When populating an ephemeral b-tree for the RHS of an IN(...) clause, avoid applying an affinity to a value that may be used later on for some other purpose. Fix for [c7a117190].
drh [Sat, 17 Aug 2019 17:07:15 +0000 (17:07 +0000)]
Ensure the functions that appear to be constant are not factored out of
expression that originate on the right-hand side of a LEFT JOIN.
Ticket [6710d2f7a13a2997]
drh [Thu, 15 Aug 2019 21:27:20 +0000 (21:27 +0000)]
Add the SQLITE_DBCONFIG_ENABLE_VIEW option, together with a "db config"
command in the TCL interface that can access that option as well as all the
other sqlite3_db_config() boolean options.
drh [Thu, 15 Aug 2019 14:35:45 +0000 (14:35 +0000)]
Ensure that the optional "sz=N" parameter that can be manually added to the
end of an sqlite_stat1 entry does not have an N value that is too small.
Ticket [e4598ecbdd18bd82]
drh [Thu, 15 Aug 2019 00:04:44 +0000 (00:04 +0000)]
Early detection out-of-bounds page numbers on the direct-overflow-read
optimization gives consistent error messages regardless of whether or not
the optimization is enabled.
drh [Sat, 10 Aug 2019 15:06:03 +0000 (15:06 +0000)]
Fix the sqliteExprImpliesExpr() routine so that it recognizes that
"(NULL IS FALSE) IS FALSE" doe not implie "NULL NOT NULL".
Ticket [9080b6227fabb466]
drh [Thu, 8 Aug 2019 19:19:42 +0000 (19:19 +0000)]
Remove support for SQLITE_ENABLE_STAT3. The sqlite_stat3 table is now ignored,
if it exists. Run ANALYZE using STAT4 to get the equivalent functionality,
which presumably everybody has been doing for a long time now.
drh [Thu, 8 Aug 2019 15:24:17 +0000 (15:24 +0000)]
Remove support for STAT3. The sqlite_stat3 tables are ignored, if they
exist. STAT4 continues to work as it always has, and as it is a superset of
STAT3 is the recommended replacement.
dan [Wed, 7 Aug 2019 18:34:21 +0000 (18:34 +0000)]
Add "set TMP=%CD%" to the start of each msvc script output by releasetest_data.tcl. Otherwise, since binaries compiled with SQLITE_TEST all choose the same sequence of pseudo-random numbers, collisions between temp file names cause errors when running multiple tests in parallel.
drh [Tue, 6 Aug 2019 15:32:42 +0000 (15:32 +0000)]
Ensure that columns of views and sub-queries that are expressions with
no affinity are comparied without any type conversions, as required in the
documentation. Tickets [61c853857f40da49] and [d52a29a9e6bc55c5].
drh [Tue, 6 Aug 2019 14:37:24 +0000 (14:37 +0000)]
Use 0x40 (ASCII '@') instead of 0x00 to mean "no affinity" so that columns
with no affinity can appear in a zero-terminated string. Use the new
SQLITE_AFF_NONE macro for this new magic number.
dan [Mon, 5 Aug 2019 20:53:19 +0000 (20:53 +0000)]
Ensure that columns of views and sub-queries that are expressions with no affinity are not assigned BLOB affinity. This matches the documentation. Fix for [61c853857f40da49].
drh [Mon, 5 Aug 2019 19:32:06 +0000 (19:32 +0000)]
One of two options on how to address ticket [61c853857f40da49]. In this
mode, we back out the documentation change of
[https://www.sqlite.org/docsrc/info/07b7749da88d54e5|[07b7749da88d54e5]]
and change the core to work as it has been documented to work since 2017,
rather than how it has actually worked since 2009.
drh [Mon, 5 Aug 2019 18:01:42 +0000 (18:01 +0000)]
Refactor field Expr.affinity into Expr.affExpr to avoid confusion with other
fields and variables named "affinity" and display affExpr it in
sqlite3TreeViewExpr() output.
dan [Mon, 5 Aug 2019 13:19:25 +0000 (13:19 +0000)]
Fix a problem with renaming a table when a view or trigger within the schema uses a FILTER with an aggregate function that is not currently registered with the database.
drh [Sat, 3 Aug 2019 01:39:20 +0000 (01:39 +0000)]
Give the SQLITE_TESTCTRL_PRNG_SEED two arguments. The second argument if not
NULL is a pointer to a database connection which seeds the connection from
its schema cookie. In this way, fuzzers can control the PRNG seed.
dan [Fri, 2 Aug 2019 19:40:01 +0000 (19:40 +0000)]
If a query like "SELECT min(a), b FROM t1" visits no rows where "a" is not null, extract a value for "b" from one of the rows where "a" is null. Fix for ticket [41866dc37].
dan [Fri, 2 Aug 2019 18:43:59 +0000 (18:43 +0000)]
If a query like "SELECT min(a), b FROM t1" visits no rows where "a" is not null, extract a value for "b" from one of the rows where "a" is null. Possible fix for ticket [41866dc37].
drh [Thu, 1 Aug 2019 22:48:45 +0000 (22:48 +0000)]
The sqlite3_set_authorizer() interface should only expire prepared statements
when it is setting a new authorizer, not when clearing the authorizer. And
statements that are running when sqlite3_set_authorizer() is invoked should be
allowed to continue running to completion.
dan [Wed, 31 Jul 2019 21:08:55 +0000 (21:08 +0000)]
Update "releasetest_data.tcl" so that it is a standalone script that generates sh or batch scripts to run each tcl test run at release time. Update wapptest.tcl to use it.
Improved fix for ticket [ced41c7c7d6b4d36] that keeps skip-scan enabled,
but avoids identifying a skip-scan as order-distinct (because it is not)
and thus forces a separate b-tree to implement the DISTINCT clause of a
query. This undoes check-in [a871d69c6de65038] and substitutes a new fix.
dan [Mon, 29 Jul 2019 15:32:01 +0000 (15:32 +0000)]
When using an index for both DISTINCT and ORDER BY, do not confuse the number of columns required for distinctness with the number required to get the correct sort order. Fix for [6749cb3c].
dan [Mon, 29 Jul 2019 14:42:56 +0000 (14:42 +0000)]
When using an index for both DISTINCT and ORDER BY, do not confuse the number of columns required for distinctness with the number required to get the correct sort order. Fix for [6749cb3c].
Fix the OP_Affinity operator so that when applying REAL affinity, it
only sets MEM_IntReal if the integer value will fit in 6 bytes or less.
Fix for ticket [ba2f4585cf495231]
dan [Wed, 24 Jul 2019 08:15:09 +0000 (08:15 +0000)]
Improve the ".recover" command in the shell tool so that it is not confused by auto-vacuum databases. And so that it can recover tables for which one or more of the column names are SQL keywords.
dan [Mon, 22 Jul 2019 16:33:02 +0000 (16:33 +0000)]
Remove Window objects from the corresponding Select.pWin list when they are deleted, as they are, for example, when the ORDER BY clause is optimized out.