SQLite

Check-in [d04b2013]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fix test cases so that they work with ICU.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: d04b2013b5436430ebbf7053d637fd89c1b15affcb42787dcf1cf5ffc3ae54e2
User & Date: drh 2018-09-28 23:53:24
Context
2018-10-01
07:04
Fix a problem with ALTER TABLE commands when the schema features an INSTEAD of trigger that uses NEW.* or OLD.*. (check-in: c52f457e user: dan tags: trunk)
2018-09-28
23:53
Fix test cases so that they work with ICU. (check-in: d04b2013 user: drh tags: trunk)
20:46
Have sqlite3changegroup_output_strm() call its output function more regularly. (check-in: 8467c31a user: dan tags: trunk)
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to test/like3.test.

126
127
128
129
130
131
132

133
134
135
136
137

138
139
140
141
142
143
144
} {
  QUERY PLAN
  `--SCAN TABLE t5a
}
do_execsql_test like3-5.110 {
  SELECT x FROM t5a WHERE x LIKE '/a%';
} {/abc}

do_eqp_test like3-5.111 {
  SELECT x FROM t5a WHERE x LIKE '/a%';
} {
  QUERY PLAN
  `--SEARCH TABLE t5a USING COVERING INDEX sqlite_autoindex_t5a_1 (x>? AND x<?)

}
do_execsql_test like3-5.120 {
  SELECT x FROM t5a WHERE x LIKE '^12%' ESCAPE '^';
} {123}
do_eqp_test like3-5.121 {
  SELECT x FROM t5a WHERE x LIKE '^12%' ESCAPE '^';
} {







>





>







126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
} {
  QUERY PLAN
  `--SCAN TABLE t5a
}
do_execsql_test like3-5.110 {
  SELECT x FROM t5a WHERE x LIKE '/a%';
} {/abc}
ifcapable !icu {
do_eqp_test like3-5.111 {
  SELECT x FROM t5a WHERE x LIKE '/a%';
} {
  QUERY PLAN
  `--SEARCH TABLE t5a USING COVERING INDEX sqlite_autoindex_t5a_1 (x>? AND x<?)
}
}
do_execsql_test like3-5.120 {
  SELECT x FROM t5a WHERE x LIKE '^12%' ESCAPE '^';
} {123}
do_eqp_test like3-5.121 {
  SELECT x FROM t5a WHERE x LIKE '^12%' ESCAPE '^';
} {

Changes to test/window6.test.

143
144
145
146
147
148
149

150
151
152
153
154
155
156
157
158
159
160

161
162
163
164
165
166
167
168

169
170
171

172
173
174
175
176
177
178
  SELECT count(*) OVER win FROM over
  WINDOW win AS (ORDER BY x ROWS BETWEEN +2 FOLLOWING AND +3 FOLLOWING)
} {1 0 0}

#-------------------------------------------------------------------------
#


do_execsql_test 6.0 {
  SELECT LIKE('!', '', '!') x WHERE x;
} {}

do_execsql_test 6.1 {
  SELECT LIKE("!","","!")""WHeRE"";
} {}

do_catchsql_test 6.2 {
  SELECT LIKE("!","","!")""window"";
} {1 {near "window": syntax error}}


reset_db 
do_execsql_test 7.0 {
  CREATE TABLE t1(x TEXT);
  CREATE INDEX i1 ON t1(x COLLATE nocase);
  INSERT INTO t1 VALUES('');
}


do_execsql_test 7.1 {
  SELECT count(*) FROM t1 WHERE x LIKE '!' ESCAPE '!';
} {0}


#-------------------------------------------------------------------------
#
do_execsql_test 8.0 {
  CREATE TABLE IF NOT EXISTS "sample" (
      "id" INTEGER NOT NULL PRIMARY KEY, 
      "counter" INTEGER NOT NULL, 







>
|
|
|
<
|
|
|
<
|
|
|
>








>
|
|
|
>







143
144
145
146
147
148
149
150
151
152
153

154
155
156

157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
  SELECT count(*) OVER win FROM over
  WINDOW win AS (ORDER BY x ROWS BETWEEN +2 FOLLOWING AND +3 FOLLOWING)
} {1 0 0}

#-------------------------------------------------------------------------
#

ifcapable !icu {
  do_execsql_test 6.0 {
    SELECT LIKE('!', '', '!') x WHERE x;
  } {}

  do_execsql_test 6.1 {
    SELECT LIKE("!","","!")""WHeRE"";
  } {}

  do_catchsql_test 6.2 {
    SELECT LIKE("!","","!")""window"";
  } {1 {near "window": syntax error}}
}

reset_db 
do_execsql_test 7.0 {
  CREATE TABLE t1(x TEXT);
  CREATE INDEX i1 ON t1(x COLLATE nocase);
  INSERT INTO t1 VALUES('');
}

ifcapable !icu {
  do_execsql_test 7.1 {
    SELECT count(*) FROM t1 WHERE x LIKE '!' ESCAPE '!';
  } {0}
}

#-------------------------------------------------------------------------
#
do_execsql_test 8.0 {
  CREATE TABLE IF NOT EXISTS "sample" (
      "id" INTEGER NOT NULL PRIMARY KEY, 
      "counter" INTEGER NOT NULL, 
332
333
334
335
336
337
338
339
    FROM t1 ORDER BY a;
} {
  10 ten 10   15 fifteen 25   20 {} 65        20 {} 65   
  25 {} 90    30 thirty 150   30 thirty 150   50 {} 200
}

finish_test








<
334
335
336
337
338
339
340

    FROM t1 ORDER BY a;
} {
  10 ten 10   15 fifteen 25   20 {} 65        20 {} 65   
  25 {} 90    30 thirty 150   30 thirty 150   50 {} 200
}

finish_test