drh [Tue, 13 Feb 2007 12:49:24 +0000 (12:49 +0000)]
Expand the cursor index in SrcList_item to 32-bits to accomodate really
huge VDBE programs resulting from deeply nested triggers. This is an
interim fix until we rework triggers to use subroutines. (CVS 3640)
drh [Wed, 7 Feb 2007 13:09:45 +0000 (13:09 +0000)]
Explicit collations always override implicit collations. This is
backwards compatible since SQLite has not previously supported
explicit collations. Need to add tests of this new behavior. (CVS 3633)
drh [Wed, 7 Feb 2007 01:06:52 +0000 (01:06 +0000)]
Change the coding of PRAGMA count_changes so that it uses memory cells
of the VM rather than the stack, to avoid problems with leftovers on the
stack interfering with other operations. Ticket #2217. (CVS 3632)
shess [Wed, 7 Feb 2007 01:01:17 +0000 (01:01 +0000)]
http://www.sqlite.org/cvstrac/tktview?tn=2219
When creating fts tables in an attached database, the backing tables
are created in database 'main'. This change propagates the
appropriate database name to the routines which build sql statements.
Note that I propagate the database name and table name separately. I
briefly considered just making the table name be "db.table", but it
didn't fit so well in the model used to store the table name and other
information, and having the db name passed separately seemed a bit
more transparent. (CVS 3631)
drh [Tue, 6 Feb 2007 13:26:32 +0000 (13:26 +0000)]
When optimizing out an ORDER BY clause due to uniqueness constraints, make
sure unused terms to the right in the ORDER BY clause to not reference other
tables in a join. Ticket #2211. Additional test cases needed before
closing this ticket. (CVS 3629)
drh [Fri, 2 Feb 2007 12:44:37 +0000 (12:44 +0000)]
Minor tweaks to collating sequences. We'll hold of making major changes
until 3.4.0, since we'll likely end up with some minor technical
imcompatibilities. (CVS 3626)
drh [Thu, 1 Feb 2007 23:02:45 +0000 (23:02 +0000)]
First cut at adding the COLLATE operator. Regression tests pass (or at least
the quick set does) and a few new tests have been added. But many more
tests are needed. Rules for combining collations need to be worked out. (CVS 3624)
drh [Sat, 27 Jan 2007 02:38:29 +0000 (02:38 +0000)]
Parser changes to allow parenthesized numerical arguments to pragmas,
in support of the integrity_check enhancement of check-in (3609)
and ticket #2176. (CVS 3610)
drh [Sat, 27 Jan 2007 02:24:54 +0000 (02:24 +0000)]
Limit the number of errors returned by PRAGMA integrity_check to 100 by
default. Specify an alternative limit using an argument to the pragma.
Ticket #2176. (CVS 3609)
drh [Fri, 26 Jan 2007 19:23:33 +0000 (19:23 +0000)]
Add code to select.c for printing the contents of parse-tree structures.
The code is normally omitted. You must compile with -DSQLITE_TEST
or -DSQLITE_DEBUG to enable it. (CVS 3606)
shess [Fri, 19 Jan 2007 22:59:56 +0000 (22:59 +0000)]
http://www.sqlite.org/cvstrac/tktview?tn=2166,35
Calling UPDATE against an fts table in a UTF-16 database inserts
corrupted data into the database. The UTF-8 data is being inserted
directly. This appears to happen because sqlite3_ value_text()
destructively coerces a value to UTF-8, and it's never converted back
when updating the table. This works around the problem by rearranging
things so that the update happens before the coercion. (CVS 3596)
drh [Fri, 19 Jan 2007 01:06:01 +0000 (01:06 +0000)]
Make sure the IS NULL optimization introduced by check-in (3494) correctly
handles a LEFT JOIN where the a term from the right table of the join uses
an IS NULL constraint. Ticket #2177. This check-in also adds the new test
cases that were suppose to have been added with (3494) but which were
mistakenly omitted. (CVS 3595)
drh [Tue, 16 Jan 2007 18:19:12 +0000 (18:19 +0000)]
Additional memory initialization in lemon - bug reported from wireshark.
Ticket #2172. Note this problem only comes up with certain grammars,
and does not impact SQLite. On the other hand, it might cause SQLite
to run slower. So we might want to revisit this change at some point. (CVS 3594)
drh [Tue, 16 Jan 2007 03:09:02 +0000 (03:09 +0000)]
Make sure the parser generated by lemon always calls destructors on
unused symbols, even if there is no action following the rule.
Ticket #2171. (CVS 3593)
drh [Fri, 12 Jan 2007 23:09:23 +0000 (23:09 +0000)]
Fix a bug in lemon. The code in which the error appears might well be
unreachable. The changes does not effect the code that is generated for
the SQLite parser. Ticket #2164. (CVS 3591)
drh [Tue, 9 Jan 2007 14:01:13 +0000 (14:01 +0000)]
When an automatic re-prepare occurs, take care not to reset the internal
schema symbol table. Ticket #2156. This change also includes some debugging
enhancements. (CVS 3578)
drh [Mon, 8 Jan 2007 21:07:17 +0000 (21:07 +0000)]
Fix a critical bug in sqlite3_prepare_v2 that can lead to segfaults when
the schema changes and the statement is recompiled automatically.
Ticket #2154. (CVS 3576)
drh [Fri, 5 Jan 2007 02:00:47 +0000 (02:00 +0000)]
In the btree.c, when releasing the page1 lock, first make sure the
pager has not reset and released the lock already. This fixes a bug
introduced by (3549). (CVS 3563)
drh [Wed, 3 Jan 2007 23:37:28 +0000 (23:37 +0000)]
Clean up memory leaks and uninitialized variables detected by valgrind.
Identify all tests where we deliberately derefence freed memory by adding
a "-misuse" tag. (CVS 3550)
drh [Wed, 3 Jan 2007 23:36:22 +0000 (23:36 +0000)]
Additional changes in the pager and os interface layers to fix problems that
might be contributing to recently observed database corruption. (CVS 3549)
drh [Wed, 3 Jan 2007 15:34:29 +0000 (15:34 +0000)]
Make sure that the database size cache in the pager is invalidated whenever
the database is unlocked. A stale value in the database size cache can
result in database corruption on a heavily loaded system running
autovacuum. (CVS 3548)
drh [Tue, 2 Jan 2007 18:41:54 +0000 (18:41 +0000)]
Update the vtab_err test to check for -DSQLITE_MEMDEBUG=1 and skip the tests
if missing. Pager is more careful to clear its file size cache. Remove
an assert() in VDBE that might fail on a corrupt database file. (CVS 3547)
pweilbacher [Fri, 22 Dec 2006 20:33:13 +0000 (20:33 +0000)]
OS/2 change: add safeguard to be able to use SQLite loaded into high memory on OS/2 when compiled with GCC 3.3 or later. Currently, this is only used when building within the Mozilla source tree. (CVS 3546)
drh [Thu, 21 Dec 2006 22:38:23 +0000 (22:38 +0000)]
Disable extension loading by default. At some point we should change
the configure script to detect the presence of dlopen() automatically
and add the appropriate library to the link. But that requires a
working version of autoconf, which I do not have. Ticket #2124. (CVS 3545)
drh [Thu, 21 Dec 2006 01:29:22 +0000 (01:29 +0000)]
Move the shared-library loading routines into the OS portability layer,
thus enabling the os_win.c code to handle the character encoding
confusion of win95/nt/ce. Ticket #2023. (CVS 3541)