Commit Graph

16695 Commits

Author SHA1 Message Date
mistachkin
8145fc6eda Fix typo in the name of a Win32 string conversion routine. Replace several uses of raw_printf() with utf8_printf() in the shell.
FossilOrigin-Name: 6fc95dd7a0b44212f30e657a850892a85a12715c
2016-09-16 20:39:21 +00:00
drh
7152cc0641 If no KEY is specified on ATTACH, copy the main schema key if the key size
is non-zero.  In other words, allow for -1 as a valid key size in support
of the --textkey to SEE.

FossilOrigin-Name: 03573887dbf357f8aa54e4a1cd03b82b0ded8139
2016-09-16 19:42:47 +00:00
drh
d145915a59 Fix problems with the fileRead() function in the command-line shell. Fix
a harmless memory leak in the command-line shell, to make validation testing
easier.

FossilOrigin-Name: e660402e5e654b7f37ad2ce201df5cbb2b9eb9a6
2016-09-16 19:11:03 +00:00
drh
0882da8001 Remove the #ifdef SQLITE_DEBUG from around the testcase_glob() routine
in the command-line shell.

FossilOrigin-Name: 9885dac4b98693c4d2ed643022127f1452f19dc6
2016-09-16 18:53:42 +00:00
dan
edc3537c61 Fix a problem causing incorrect code to be generated for IN constraints like "a IN (1, 2, 3)" where column "a" is a rowid column with an extra UNIQUE index created on it. Ticket [0eab1ac759].
FossilOrigin-Name: a92aee5520cfaf85ae896365a7e42bdd981f828d
2016-09-16 16:30:57 +00:00
drh
72d5003ed8 Replace a faulty assert() with a testcase() to assure the condition is
tested.

FossilOrigin-Name: a49bc0a8244feb08b83e716d81c2a9512c184539
2016-09-16 15:42:17 +00:00
drh
4313f045c2 Add WHERETRACE macros showing every entry and exit from
whereLoopAddBtreeIndex().

FossilOrigin-Name: e7653decdcee161d379ced40aa1b27246337b000
2016-09-16 14:50:38 +00:00
drh
a0daa751f8 Fix SQLITE_OMIT_AUTHORIZATION so that it compiles cleanly.
FossilOrigin-Name: a3e3b3e1c57178ccd38fc7375ec1de8e8ae45372
2016-09-16 11:53:10 +00:00
drh
760c8162ff In the shell, make ".testcase" and ".check" available in all configurations,
not just SQLITE_DEBUG.  All testcases to be named.  Show the result of each
testcase on stdout.

FossilOrigin-Name: 792afefa9c750910082fd102f1ccd10309759dfc
2016-09-16 02:52:22 +00:00
drh
cd0509e256 In the command-line shell, add the --new option to the ".open" command.
Also, report the current database filename as part of the ".show" command.

FossilOrigin-Name: 8e5c92039128a430e0509f4f06ea80ba39c35bda
2016-09-16 00:26:08 +00:00
drh
2db8211526 Add the ".testcase" and ".check" dot-commands in the shell, when compiled
using SQLITE_DEBUG.

FossilOrigin-Name: 62289f27ee276090a855982bd8216a465e7d0a27
2016-09-15 21:35:24 +00:00
drh
98365be030 Omit the sqlite3Apis constant object when compiling with
SQLITE_OMIT_LOAD_EXTENSION, since it is not used.

FossilOrigin-Name: 7b10461370828b9c57acaaaea518031d53986fa3
2016-09-15 19:15:19 +00:00
drh
21e19b44f0 Remove no-op code (adding an assert() to prove that the code was no-op)
in the text affinity logic of the bytecode engine comparison operators.

FossilOrigin-Name: b9f5bdbf40ac6382e48f09ebcd53cc908e065527
2016-09-15 14:54:51 +00:00
dan
95489c58f7 Fix a typo in a comment in sqlite.h.in. No changes to code.
FossilOrigin-Name: 12df7152109ffce4b3e0ee233c5ea8103edb902a
2016-09-15 05:47:00 +00:00
drh
72ceae01e5 Slight size reduction and performance increase in sqlite3VdbeHalt().
FossilOrigin-Name: 5990a1bdb4a0734ff23015ada71cf02d0cb1381f
2016-09-15 00:32:42 +00:00
drh
5f6eb1a0dc Optimization to vdbeRecordCompareInt() makes it slightly smaller and faster.
FossilOrigin-Name: 5a2a7712cb8e0b686942dfab4e9e67b5ea7b2be3
2016-09-15 00:04:46 +00:00
drh
481fd50cb4 Update comments used to generate API documentation to include the new
"[dateof:3.X.Y]" notation for dates of release where appropriate.
No changes to code.

FossilOrigin-Name: 55f7f8ee5b1c13aa219198b7ae66f59b3730f4c3
2016-09-14 18:56:20 +00:00
dan
12c56aa452 Fix a bug in sqldiff causing it to confuse blobs zero bytes in size with NULL values.
FossilOrigin-Name: 264e9c75875796cad773d39b775d4604546bc57a
2016-09-12 14:23:51 +00:00
dan
ff02e200c0 Add missing "finish_test" command to vacuum5.test.
FossilOrigin-Name: 02f40c3b934ba79f2d45eae3781f2bea0c69c95f
2016-09-12 13:32:37 +00:00
dan
d562ec277c Have releasetest.tcl delete all test files except for "testfixture", "testfixture.exe", "sqlite3", "sqlite3.exe", "test.log" and "test-out.txt" after each test run is finished. Passing the "--keep" option restores the old behaviour.
FossilOrigin-Name: e0e042dca98f29c060f76db079afecb3200ffae5
2016-09-12 09:28:21 +00:00
drh
2eb22af03d Changes to give a warning-free build with SQLITE_OMIT_INCRBLOB and
SQLITE_OMIT_SHARED_CACHE.

FossilOrigin-Name: 711c59171b22df04224183a713e6c36e0bb3bba8
2016-09-10 19:51:40 +00:00
dan
9871664ed6 Add test code to delete an SQLite database and its auxiliary files.
FossilOrigin-Name: 8a9d128119fde36c175735be56876d30e5c8586f
2016-09-10 14:43:07 +00:00
mistachkin
35cd8b1eb5 Make the new file test_delete.c portable to MSVC on Windows.
FossilOrigin-Name: 0e3ace39f234c204649ec69c6a69fb0e062c58f7
2016-09-09 20:26:27 +00:00
drh
27fe1c3fcc Remove an unnecessary call to sqlite3VdbeMemExpandBlob() when casting to
text.

FossilOrigin-Name: 19e2e5950541f1a93eed994cc2b1eaf64b68e858
2016-09-09 20:23:59 +00:00
dan
000f95b1ba Add new file test_delete.c, containing test code for deleting an sqlite database.
FossilOrigin-Name: fb0b95e9405a3180d13c6318409af361e9df7632
2016-09-09 20:00:40 +00:00
drh
64caee4086 Performance improvements to the comparison operators in the bytecode engine.
FossilOrigin-Name: 37803b19d219f4107f29b240d5d314600e4bd236
2016-09-09 19:33:00 +00:00
drh
b80dbdc2f7 Fix a out-of-order variable declaration for some compile-time configurations.
FossilOrigin-Name: 6ac932c92a61cd68cc5b1816216e4748a5c7b3cd
2016-09-09 15:12:41 +00:00
drh
fe3765828a In releasetest.tcl, the --srcdir option is automatic, so no need to mention
it in the --help output.

FossilOrigin-Name: 2bdd838e2c434f1d26b1836ef39fa938ef93131d
2016-09-09 13:23:36 +00:00
drh
2c33183d11 Fix an obsolete comment in the releasetest.tcl source code.
FossilOrigin-Name: afaaa276b256f56adf63cb568e486cb3315c3ec2
2016-09-09 13:17:26 +00:00
drh
eedeb92caa In releasetest.tcl:
Improved testing for uncommitted changes.  If uncommitted changes are seen,
exit immediately unless the --force option is used.

FossilOrigin-Name: 9a14e6c46cdda9f10151ee96a0540798573edcf2
2016-09-09 12:29:57 +00:00
drh
1fbd008cf4 Issue a warning and prompt the user to continue if the releasetest.tcl script
is run in a checkout with uncommitted changes.

FossilOrigin-Name: 30e917fff05b02ce2cb1f1c871d638200fbe5716
2016-09-08 23:12:08 +00:00
drh
f78dcd1b96 Add support for row-value comparisons, including IN operators, and
row-value updates in the UPDATE statement.

FossilOrigin-Name: ddb5f0558c44569913d22781ab78f3e9b58d7aea
2016-09-07 19:54:24 +00:00
dan
26c8d0ca21 Fix a problem handling expressions like "(a, b) IN (SELECT ... ORDER BY 1, 2)" when there is an index on "a" but not "b".
FossilOrigin-Name: 7f2c5c9ee3628c968306a5ab2e5a9a761f1b8055
2016-09-07 19:37:20 +00:00
drh
d609bdb9d3 Add the ext/misc/memvfs.c extension that implements a VFS for read-only
database files contained in memory.

FossilOrigin-Name: 12b7782a9af91eab913e159149cb28b3f5a6557c
2016-09-07 18:11:11 +00:00
drh
c097e122b9 Simplify the affinity handling logic in codeAllEqualityTerms(). Logically
the same, just a little easier to read and understand.

FossilOrigin-Name: bbab9621f512b04684163b98b6fc669c68038044
2016-09-07 13:30:40 +00:00
drh
af6f65fb26 Merge fixes from trunk.
FossilOrigin-Name: 193f036c87857bd77577ceb462af5034c7cc77da
2016-09-07 13:12:13 +00:00
drh
fc8b40f2f6 Fix the ".read" command in the command-line shell so that it understands
that the input is not interactive.

FossilOrigin-Name: d8451fe84d09db6ec7e1bd5f0708ea1b5e85f3d6
2016-09-07 10:10:18 +00:00
drh
57a8c61501 The ORDER BY LIMIT optimization is not valid unless the inner-most IN operator
loop is actually used by the query plan.
Fix for ticket [0c4df46116e90f92].

FossilOrigin-Name: 820644b886f81e991fceb5f1c3290b8959b34528
2016-09-07 01:51:46 +00:00
drh
63cecc4173 Remove obsolete vector-IN test cases. Fix a bad testcase() macro.
FossilOrigin-Name: ab3f8f193a7ec36018bf26c9231a1a6a58b6a523
2016-09-06 19:08:21 +00:00
drh
1431807a0b Fix corer cases of vector IN operators where the RHS is a compound SELECT
that includes an ORDER BY clause.

FossilOrigin-Name: 8329ac6f8d1edcc19c3e0559abe9a8011dbe1497
2016-09-06 18:51:25 +00:00
dan
773d3afaa3 Remove an unnecessary branch from expr.c.
FossilOrigin-Name: 7cc9746c5414e02012efb8180f9eca2646800e74
2016-09-06 17:21:17 +00:00
drh
c7a77ae1c6 Avoid unnecessary memory allocations for aiMap in codeEqualityConstraints.
FossilOrigin-Name: 70319c3d76abd1e403fcf2a62668736b92a5f3d5
2016-09-06 17:13:40 +00:00
drh
aaf8a0643e Avoid a NULL pointer deref in codeAllEqualityConstraints() following an OOM.
FossilOrigin-Name: c6e528c1c0f17c69c7745b018afa36694118258f
2016-09-06 16:53:53 +00:00
dan
1c12657f9a Simplify the fix in commit [7d9bd22c].
FossilOrigin-Name: bd5a342008575bf66f63881a0bebf43741f2a67b
2016-09-06 16:33:24 +00:00
drh
099a0f5f54 Fix the header comment on codeEqualityTerm().
FossilOrigin-Name: b7e710e406ed22bcc316099b5e200b6bb2d9c872
2016-09-06 15:25:53 +00:00
dan
83c434e68d Fix a problem handling (a, b) IN (SELECT ...) expressions when there is an index on just one of "a" or "b".
FossilOrigin-Name: 231c72d9f651f3a70d5c8af080f3ff181b89d939
2016-09-06 14:58:15 +00:00
drh
ed24da4b16 Enhance the sqlite3GetTempRange() and sqlite3ReleaseTempRange() internal
routines so that they use sqlite3GetTempReg() and sqlite3ReleaseTempReg()
when nReg==1.

FossilOrigin-Name: 4071da2f87a2f24a279ac3bced8c794ad374b47c
2016-09-06 14:37:05 +00:00
dan
fad0e70c63 Fix a typo in a comment in expr.c.
FossilOrigin-Name: 288e934f356ff6276b3e7581ac0f998ca6e93610
2016-09-06 12:04:50 +00:00
drh
9f24b53dcc Simplified logic to extract a column from a row value.
FossilOrigin-Name: e8f105c3009e9b667db2afc0088b020a2b94d370
2016-09-05 22:50:48 +00:00
drh
c1bcd9cc3e Fix an assert() so that it does C-compiler does not combine an assert()
conditional with a production code conditional and thereby confuse the mutation
testing script.

FossilOrigin-Name: 2fa5288a7ef43f1fb26037c1b5e84b7b90400623
2016-09-05 19:57:46 +00:00