1751 Commits

Author SHA1 Message Date
drh
f998b730dd Additional out-of-memory testing. Fix bugs caused by malloc failures in
where.c.  Tickets #2794, #2795, #2796, and #2797. (CVS 4560)

FossilOrigin-Name: 5e02dbabcfa42173adff234c086df1e962824c92
2007-11-26 13:36:00 +00:00
drh
0f31c45c10 Fix a typo in a change to all.test from earlier today. (CVS 4557)
FossilOrigin-Name: 8c0b2157f2a2f8ecfa641a041279faf21aedd4e0
2007-11-23 18:19:22 +00:00
drh
613a0fe455 Changes fts3 to use only sqlite3_malloc() and not system malloc.
Ticket #2762. (CVS 4554)

FossilOrigin-Name: 460af6bb668094c99a1d4dc1540b44b6d1d036b6
2007-11-23 17:31:17 +00:00
drh
48d1178ad8 Make sure that INSERT INTO ... SELECT ... always uses an ephemeral
intermediate table if the SELECT clause refers to the destination table,
even if the SELECT clause is compound or uses the destination table
in a subquery.  This fixes a long-standing bug that can cause an
infinite loop for some SQL statements. (CVS 4552)

FossilOrigin-Name: 492b39b6a8bf4ad8792d7a7949f77827a5047fd8
2007-11-23 15:02:19 +00:00
drh
f4ce8ed048 Avoid a double-free in an out-of-memory situation with a USING
clause or NATURAL JOIN.  Ticket #2789. (CVS 4551)

FossilOrigin-Name: 596694752c5935ae50ad38d3b41bbda39ca999d8
2007-11-23 13:42:51 +00:00
drh
cfa063b377 Handle out-of-memory situations inside the query flattener.
Ticket #2784. (CVS 4549)

FossilOrigin-Name: 2655a3f2d18fe16a36a6cf3776261ee0507e6912
2007-11-21 15:24:00 +00:00
danielk1977
932083c60f Fix a crash that can occur after a malloc failure. Ticket #2775. (CVS 4547)
FossilOrigin-Name: c91bc8d33306881cb2501070dccced92c82cf165
2007-11-16 14:55:46 +00:00
shess
cd7274ceb0 Don't do anything when input doclists are both empty. Ticket #2774 (CVS 4546)
FossilOrigin-Name: 75cb46f82a6a95dbe9e279dede299bafa2e91cae
2007-11-16 00:23:07 +00:00
danielk1977
b8b4bfa061 Fix a segfault that can occur after a malloc failure in an ANALYZE statement. Ticket #2772. (CVS 4544)
FossilOrigin-Name: d05eb67dd6e171cfe8b9528aa3c7c953780d8c82
2007-11-15 13:10:22 +00:00
danielk1977
8e556520e9 Modify the Tcl interface to use sqlite3_prepare_v2(). (CVS 4542)
FossilOrigin-Name: 7bb00c7df672cb8988121f30e3bbdea9ad951603
2007-11-13 10:30:24 +00:00
danielk1977
3c4809a201 Where possible, transform the DISTINCT qualifier to a GROUP BY clause. GROUP BY clauses may be optimized by indices, DISTINCT qualifiers cannot. (CVS 4538)
FossilOrigin-Name: e56331234791cf3d830a30e4cfa66682bdf2eed1
2007-11-12 15:29:18 +00:00
danielk1977
390025053e Allow collation sequence names to be quoted. Ticket #2744. (CVS 4537)
FossilOrigin-Name: 06749ac7afeea4adbdeb9315f3819d5224534c66
2007-11-12 09:50:26 +00:00
drh
95c0775484 Fix the code generation for UPDATE and DELETE so that
BEFORE triggers that use RAISE(IGNORE) do not leave extra
values on the stack.  Ticket #2767 (CVS 4535)

FossilOrigin-Name: 3391f4139ccfe62cc27739a06567c422ddae9c69
2007-11-11 18:36:34 +00:00
danielk1977
7eb42c8204 Reset the writer-thread halt criteria after halting the thread. (CVS 4528)
FossilOrigin-Name: ecbff972a1f5c7d846c322c435fa73584655b7f0
2007-11-05 17:01:08 +00:00
danielk1977
662278e4de Fix some minor problems with malloc failure and in-memory databases. (CVS 4527)
FossilOrigin-Name: b752906e708e1c8c76084152f5829e16e8988ef2
2007-11-05 15:30:12 +00:00
drh
0152123730 Fix a bug in the misc1 test script. (CVS 4526)
FossilOrigin-Name: fa16996d99cdce9f652508e3a70b7e5747810823
2007-11-05 14:58:23 +00:00
danielk1977
6d64307b03 Handle "IS NULL" constraints on virtual table scans. IS NULL constraints are not passed to the virtual table layer. Ticket #2759. (CVS 4523)
FossilOrigin-Name: 7027368c15b3270a139bea5612d7c03c2288dcc4
2007-11-05 05:12:53 +00:00
drh
0cf19ed817 Add comments, assertions, and test cases to demonstrate that the
problem described in ticket #2742 is not a real problem. (CVS 4510)

FossilOrigin-Name: c085d6dfc0f5849113986cb2a25e64d0c95b3dfb
2007-10-23 18:55:48 +00:00
drh
598f134020 Floating point and 64-bit integer constants store in the virtual
machine opcodes in binary, not as text.  Performance improvement.
Ticket #2733. (CVS 4507)

FossilOrigin-Name: 7e30fd6a09899842c922b044714dc66796e545d4
2007-10-23 15:39:45 +00:00
drh
9bc5449f9d Make sure the sqlite3_vfs_register() and sqlite3_vfs_unregister() APIs
work right even if not VFS is currently registered.  Ticket #2738. (CVS 4505)

FossilOrigin-Name: c36500871e85b55cb0804d5c9e88fa6861a507a9
2007-10-23 14:49:59 +00:00
danielk1977
0d6e7a00d6 Add speed4.test, with some speed tests for triggers, sub-selects, views and joins. (CVS 4504)
FossilOrigin-Name: 3e3475b9e0f996841aa40419693c7c3eaa6c71aa
2007-10-23 10:25:30 +00:00
danielk1977
191fadcf23 Fix an error message in the tcl interface. (CVS 4503)
FossilOrigin-Name: 2449e08069ef830f119203c4a3737d6756e73c63
2007-10-23 08:17:48 +00:00
danielk1977
1c1764ae66 Add the NEAR operator to fts3. (CVS 4502)
FossilOrigin-Name: aef7720e0bb49d52332ddebe6f698feb926ef7d7
2007-10-22 18:02:20 +00:00
drh
a4e5d58f02 Simplify the mem3.c memory allocator. Have it call sqlite3_release_memory()
automatically, without having to specify the soft heap limit. (CVS 4496)

FossilOrigin-Name: ca51b2f54076fcf73a8857aecf4b45d66ef0c7b6
2007-10-20 15:41:57 +00:00
drh
d2bb3278e0 Add a malloc size histogram to the debugging malloc implementation
in mem2.c. (CVS 4490)

FossilOrigin-Name: 3e51696cb878063e4ebfdcc2a61ba94c9bebdfe3
2007-10-15 19:34:32 +00:00
drh
a6d0ffc359 Do not invoke the authorizer when reparsing the schema after a schema
change or when trying to figure out the result set of a view. (CVS 4488)

FossilOrigin-Name: e756bc9b74ef357c088b3044527c41e6834ba1a2
2007-10-12 20:42:28 +00:00
drh
64f31519b7 Make the 3rd parameter of the SUBSTR() function optional. Ticket #2579. (CVS 4486)
FossilOrigin-Name: 4a807d48ea9923c1e3df4a5ad503710e62ae29f8
2007-10-12 19:11:55 +00:00
danielk1977
5a8f9374ab Fixes to the test suite (no code changes) so that quick.test runs with OMIT_ATTACH builds. #2706. (CVS 4480)
FossilOrigin-Name: 07c00fffe50e8380748f7ae02328531a75d64610
2007-10-09 08:29:32 +00:00
danielk1977
382e28fa0c Changes to a couple of test scripts to handle the tcl 8.5 version of (file attributes -readonly) on mac. (CVS 4472)
FossilOrigin-Name: a51946e66badab37cd54982265631bbc5e414f8e
2007-10-05 15:53:29 +00:00
drh
7795207b1f Correct the name on the new test script for ticket #2686. (CVS 4467)
FossilOrigin-Name: d261e2c731ef97d86fa9dc3caa1ce31ee9ce78ae
2007-10-04 18:52:15 +00:00
drh
c2ded2afe0 Get io.test to work even if auto_vacuum is on by default and we are
running with a reduced maximum page size. (CVS 4463)

FossilOrigin-Name: 0d05f3fbaad44a0d3723cd543b865326acddf883
2007-10-03 21:18:19 +00:00
drh
71b890a3f6 Rollback the transaction if an SQLITE_FULL error is encountered.
This is a preliminary fix for ticket #2686.  More testing and
analysis is needed before we close the ticket. (CVS 4458)

FossilOrigin-Name: 0fb6d5a5773c282882e7283e6f8f8c009e238ff4
2007-10-03 15:30:52 +00:00
danielk1977
2a180ff9c5 Add a test case to malloc.test. (CVS 4456)
FossilOrigin-Name: 7d3f0b149bd2b9c7c12aabb93d022c0ea26f0d74
2007-10-03 15:02:40 +00:00
danielk1977
8da6021be9 Fix a problem in test script malloc5.test. (CVS 4455)
FossilOrigin-Name: 028ec36c71d6ac43c8f1cda77578d844c6955f68
2007-10-03 09:43:54 +00:00
danielk1977
ae72d98252 Add automatic recovery from the pager "error-state". Also add a new error code - SQLITE_IOERR_NOMEM. (CVS 4454)
FossilOrigin-Name: 12eca32a6a3d68d5b20eed03afdffe7599e66014
2007-10-03 08:46:44 +00:00
drh
78d1ef1a51 Add disabled test cases for ticket #2652. We will enable these test cases
after #2652 is fixed.  The fix will be difficult and will probably take
a while.  On the other hand, correlated aggregate queries have never
worked in SQLite and the problem is just now coming to light, so it is
probably not a pressing issue. (CVS 4435)

FossilOrigin-Name: 5c41619e292699c72231cff10e26dfbe9a363a00
2007-09-18 16:53:52 +00:00
danielk1977
a15db35304 Minor fixes for the OMIT_INCRBLOB compilation option. (CVS 4430)
FossilOrigin-Name: 87e37eabf0ddef252bbc12f6857d33c2b136dcd3
2007-09-14 16:20:00 +00:00
danielk1977
b61c16d987 Add demo code for a vfs that operates on a single pre-allocated file. (CVS 4429)
FossilOrigin-Name: 15680ca4821ec0652dfbe863199b4c3f2afad4ba
2007-09-14 16:19:27 +00:00
drh
326c3fca85 Add tests to prevent a regression of the short read problem discovered
in version 3.2.2. (CVS 4428)

FossilOrigin-Name: 995c63b561e935b6a1da34590cb40582f5c30cee
2007-09-14 01:48:11 +00:00
shess
d83ae45639 Add an implicit (HIDDEN) docid column. This works as an alias to
rowid, similar to how things work in SQLite tables with INTEGER
PRIMARY KEY.  Add tests to verify operation. (CVS 4426)

FossilOrigin-Name: c8d2345200f9ece1af712543982097d0b6f348c7
2007-09-13 18:14:49 +00:00
shess
0ec85ae216 Mark the table-named column HIDDEN. Add tests to make sure it's
working as expected. (CVS 4425)

FossilOrigin-Name: ca669eaf1b4af441741129bee4af02f32a7c74b8
2007-09-13 18:12:09 +00:00
drh
8e70e34a28 Fix incorrect index cost assumptions that occur after an ANALYZE.
Ticket #2643. (CVS 4424)

FossilOrigin-Name: 2cfdbfe6543bac42961deecec7d085d806e604b5
2007-09-13 17:54:40 +00:00
danielk1977
4152e677b8 Fixes for compilation/testing when the various OMIT macros are defined. (CVS 4423)
FossilOrigin-Name: c8405b15c074c94dab5e33272cf1471f458d11df
2007-09-12 17:01:45 +00:00
drh
a430ae8e54 In the query optimizer, make sure table dependencies from all terms
of a compound SELECT statement are recognized so that subqueries in
a WHERE clause are not evaluated too early.  Fix for ticket #2640. (CVS 4422)

FossilOrigin-Name: 9c9c2a1da2b6235b3b0541d1f55a02a1f350567f
2007-09-12 15:41:01 +00:00
danielk1977
e9dcd5e6e3 Add another test file to help verify thread-safety. (CVS 4419)
FossilOrigin-Name: c758cc1d885b4528c0b0ef6382119f20956d4816
2007-09-10 10:53:01 +00:00
danielk1977
49e439d934 Enhance thread001.test again, this time to also test in shared-cache mode. (CVS 4418)
FossilOrigin-Name: 54f87899033ddd892bfd3a16310f64fb42d807ae
2007-09-10 07:35:47 +00:00
danielk1977
d9b5b1177d Upgrade thread001.test to test with multiple database handles. (CVS 4417)
FossilOrigin-Name: 6ee2b8ffc4310c8e329f634f3ade058b33c53a2a
2007-09-10 06:23:53 +00:00
danielk1977
570f7e2505 Modify test_thread.c to use tcl apis for creating threads. (CVS 4415)
FossilOrigin-Name: 9b7bab7fc28201b62159e959651acb980095ad06
2007-09-07 18:40:38 +00:00
drh
b9ee493971 Fix a segfault that could occur while attempting to add new pages
to the freelist in a corrupt database. (CVS 4414)

FossilOrigin-Name: c8e85fff7ede68f0b8c8ebfe3df4b26a630abeff
2007-09-07 14:32:06 +00:00
danielk1977
44918fa036 Add the beginning of the thread-safety tests. There are more to come. (CVS 4413)
FossilOrigin-Name: 753908e8411024abd5c3da1b8c62f70e35f8734d
2007-09-07 11:29:25 +00:00