3 # The author disclaims copyright to this source code. In place of
4 # a legal notice, here is a blessing:
6 # May you do good and not evil.
7 # May you find forgiveness for yourself and forgive others.
8 # May you share freely, never taking more than you give.
10 #***********************************************************************
12 # This test is focused on edge cases in the doclist format.
15 source [file join [file dirname [info script]] fts5_common.tcl]
16 set testprefix fts5doclist
18 # If SQLITE_ENABLE_FTS5 is defined, omit this file.
25 #-------------------------------------------------------------------------
26 # Create a table with 1000 columns. Then add some large documents to it.
27 # All text is in the right most column of the table.
31 for {set i 0} {$i < 900} {incr i} { lappend cols "x$i" }
32 execsql "CREATE VIRTUAL TABLE ccc USING fts5([join $cols ,])"
35 db func rnddoc fts5_rnddoc
37 WITH ii(i) AS (SELECT 1 UNION SELECT i+1 FROM ii WHERE i<100)
38 INSERT INTO ccc(x899) SELECT rnddoc(500) FROM ii;
42 INSERT INTO ccc(ccc) VALUES('integrity-check');
45 #-------------------------------------------------------------------------
49 CREATE VIRTUAL TABLE tx USING fts5(x);
52 set doc [string repeat "abc " 5000]
55 INSERT INTO tx(rowid, x) VALUES(-9000000000000000000, $doc);
56 INSERT INTO tx(rowid, x) VALUES(9000000000000000000, $doc);
61 SELECT rowid FROM tx('abc');