aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordan <dan@noemail.net>2015-04-13 14:08:27 +0000
committerdan <dan@noemail.net>2015-04-13 14:08:27 +0000
commit481ecd95d0e4386094e1eaa2d1512998d6d7fbdd (patch)
tree78259a27f11ddd0b616cb33e7008587d27d27691
parentab06b0e5be8377fc510fcde3c2d1de773a97942d (diff)
downloadsqlite-481ecd95d0e4386094e1eaa2d1512998d6d7fbdd.tar.gz
sqlite-481ecd95d0e4386094e1eaa2d1512998d6d7fbdd.zip
Test that if the definition of a collation sequence is changed and VACUUM run, the new database contains records sorted in the (new) correct order.
FossilOrigin-Name: ce6eaac10a190b26b87bfe75918e2ef58fd7a3f9
-rw-r--r--manifest14
-rw-r--r--manifest.uuid2
-rw-r--r--test/vacuum2.test20
3 files changed, 28 insertions, 8 deletions
diff --git a/manifest b/manifest
index cf166dc94..1207568ae 100644
--- a/manifest
+++ b/manifest
@@ -1,5 +1,5 @@
-C Remove\san\sunreachable\sbranch\sfrom\sthe\sVACUUM\slogic.
-D 2015-04-13T14:03:54.116
+C Test\sthat\sif\sthe\sdefinition\sof\sa\scollation\ssequence\sis\schanged\sand\sVACUUM\srun,\sthe\snew\sdatabase\scontains\srecords\ssorted\sin\sthe\s(new)\scorrect\sorder.
+D 2015-04-13T14:08:27.490
F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f
F Makefile.in 5f78b1ab81b64e7c57a75d170832443e66c0880a
F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23
@@ -1107,7 +1107,7 @@ F test/uri.test 23662b7b61958b0f0e47082de7d06341ccf85d5b
F test/userauth01.test e740a2697a7b40d7c5003a7d7edaee16acd349a9
F test/utf16align.test 54cd35a27c005a9b6e7815d887718780b6a462ae
F test/vacuum.test ce91c39f7f91a4273bf620efad21086b5aa6ef1d
-F test/vacuum2.test af432e6e3bfc0ea20a80cb86a03c7d9876d38324
+F test/vacuum2.test aa048abee196c16c9ba308465494009057b79f9b
F test/vacuum3.test 77ecdd54592b45a0bcb133339f99f1ae0ae94d0d
F test/vacuum4.test d3f8ecff345f166911568f397d2432c16d2867d9
F test/varint.test ab7b110089a08b9926ed7390e7e97bdefeb74102
@@ -1250,7 +1250,7 @@ F tool/vdbe_profile.tcl 67746953071a9f8f2f668b73fe899074e2c6d8c1
F tool/warnings-clang.sh f6aa929dc20ef1f856af04a730772f59283631d4
F tool/warnings.sh 0abfd78ceb09b7f7c27c688c8e3fe93268a13b32
F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f
-P f666ef06869f4fb655c43daacf5034c17575d951
-R 13ae6f8a2a03926d32aaccc1e7fe4f0a
-U drh
-Z 18a3bd532998a4429c86c5536067680b
+P 65ace4b062d9454a296c5a1aa7ea7316b1507ad4
+R 10297fb20a52d4dc7c571adcebaddc36
+U dan
+Z 0a6c3062817beaba9c93ab9bd5dcc5e3
diff --git a/manifest.uuid b/manifest.uuid
index c6033ca28..fcea990f8 100644
--- a/manifest.uuid
+++ b/manifest.uuid
@@ -1 +1 @@
-65ace4b062d9454a296c5a1aa7ea7316b1507ad4 \ No newline at end of file
+ce6eaac10a190b26b87bfe75918e2ef58fd7a3f9 \ No newline at end of file
diff --git a/test/vacuum2.test b/test/vacuum2.test
index b3bfab302..0350c8ec4 100644
--- a/test/vacuum2.test
+++ b/test/vacuum2.test
@@ -15,6 +15,7 @@
set testdir [file dirname $argv0]
source $testdir/tester.tcl
+set testprefix vacuum2
# Do not use a codec for tests in this file, as the database file is
# manipulated directly using tcl scripts (using the [hexio_write] command).
@@ -227,5 +228,24 @@ do_test vacuum2-5.4 {
lappend res2 $res
} {1 2 3 4 5 6 7 8 9 10 {1 {cannot VACUUM - SQL statements in progress}}}
+#-------------------------------------------------------------------------
+# Check that if the definition of a collation sequence is changed and
+# VACUUM run, records are store in the (new) correct order following the
+# VACUUM. Even if the modified collation is attached to a PK of a WITHOUT
+# ROWID table.
+
+proc cmp {lhs rhs} { string compare $lhs $rhs }
+db collate cmp cmp
+do_execsql_test 6.0 {
+ CREATE TABLE t6(x PRIMARY KEY COLLATE cmp, y) WITHOUT ROWID;
+ CREATE INDEX t6y ON t6(y);
+ INSERT INTO t6 VALUES('i', 'one');
+ INSERT INTO t6 VALUES('ii', 'one');
+ INSERT INTO t6 VALUES('iii', 'one');
+}
+integrity_check 6.1
+proc cmp {lhs rhs} { string compare $rhs $lhs }
+do_execsql_test 6.2 VACUUM
+integrity_check 6.3
finish_test