aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/libraries/sqlite/unix/sqlite-3.5.1/test/tkt2391.test
diff options
context:
space:
mode:
authordan miller2007-10-20 02:49:29 +0000
committerdan miller2007-10-20 02:49:29 +0000
commite36d23a85ebff914d74bb541558c2b6082b78edb (patch)
tree54b58fdf162e78af64055282a6035c8d2443389d /libraries/sqlite/unix/sqlite-3.5.1/test/tkt2391.test
parent* Fixed an issue whereby avatar chat distances were being calculated against ... (diff)
downloadopensim-SC-e36d23a85ebff914d74bb541558c2b6082b78edb.zip
opensim-SC-e36d23a85ebff914d74bb541558c2b6082b78edb.tar.gz
opensim-SC-e36d23a85ebff914d74bb541558c2b6082b78edb.tar.bz2
opensim-SC-e36d23a85ebff914d74bb541558c2b6082b78edb.tar.xz
sqlite source (unix build) added to libraries
Diffstat (limited to 'libraries/sqlite/unix/sqlite-3.5.1/test/tkt2391.test')
-rw-r--r--libraries/sqlite/unix/sqlite-3.5.1/test/tkt2391.test49
1 files changed, 49 insertions, 0 deletions
diff --git a/libraries/sqlite/unix/sqlite-3.5.1/test/tkt2391.test b/libraries/sqlite/unix/sqlite-3.5.1/test/tkt2391.test
new file mode 100644
index 0000000..d192b85
--- /dev/null
+++ b/libraries/sqlite/unix/sqlite-3.5.1/test/tkt2391.test
@@ -0,0 +1,49 @@
1#
2# 2007 May 28
3#
4# The author disclaims copyright to this source code. In place of
5# a legal notice, here is a blessing:
6#
7# May you do good and not evil.
8# May you find forgiveness for yourself and forgive others.
9# May you share freely, never taking more than you give.
10#
11#***********************************************************************
12# $Id: tkt2391.test,v 1.1 2007/05/29 12:11:30 danielk1977 Exp $
13
14set testdir [file dirname $argv0]
15source $testdir/tester.tcl
16
17do_test tkt2391.1 {
18 execsql {
19 CREATE TABLE folders(folderid, parentid, foldername COLLATE binary);
20 INSERT INTO folders VALUES(1, 3, 'FolderA');
21 INSERT INTO folders VALUES(1, 3, 'folderB');
22 INSERT INTO folders VALUES(4, 0, 'FolderC');
23 }
24} {}
25
26do_test tkt2391.2 {
27 execsql {
28 SELECT count(*) FROM folders WHERE foldername < 'FolderC';
29 }
30} {1}
31
32do_test tkt2391.3 {
33 execsql {
34 SELECT count(*) FROM folders WHERE foldername < 'FolderC' COLLATE nocase;
35 }
36} {2}
37
38# This demonstrates the bug. Creating the index causes SQLite to ignore
39# the "COLLATE nocase" clause and use the default collation sequence
40# for column "foldername" instead (happens to be BINARY in this case).
41#
42do_test tkt2391.4 {
43 execsql {
44 CREATE INDEX f_i ON folders(foldername);
45 SELECT count(*) FROM folders WHERE foldername < 'FolderC' COLLATE nocase;
46 }
47} {2}
48
49finish_test