Vague. Some thoughts: How long is the text? A million? A billion?
If a million, does SQLite take what you consider a long time to
receive/display results from a TEXT row?
SELECT printf('%1000000s');
--...
Run Time: real 0.854 user 0.016000 sys 0.008000
--vs:
INSERT INTO t1(e) SELECT printf('%1000000s');
SELECT * from t1;
--...
Run Time: real 0.884 user 0.008000 sys 0.008000
On Tue, Jan 16, 2018 at 7:52 PM, Nick <[email protected]> wrote:
> I have a table below in my application:
>
> CREATE TABLE t1 (
> a INTEGER PRIMARY KEY AUTOINCREMENT,
> b INTEGER NOT NULL UNIQUE,
> c INTEGER NOT NULL,
> d INTEGER,
> e TEXT,
> f INTEGER,
> g INTEGER,
> h TEXT,
> i INTEGER,
> UNIQUE(b, i)
> );
> And I’ve got some speed issues when I query the db:
> SELECT b, c, d, e, f, g, h FROM t1 WHERE b >= 10000;
>
> It needs almost 60ms as there are about 100 records with some long TEXT
> data
> in the TEXT columns.
>
> I am wondering if it is needed to add ANY INDEX to improve the performance
> of the SELECT?
>
> Thanks.
>
>
>
> --
> Sent from: http://sqlite.1065341.n5.nabble.com/
> _______________________________________________
> sqlite-users mailing list
> [email protected]
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
[email protected]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users