[EMAIL PROTECTED] wrote:
<[EMAIL PROTECTED]> wrote:
LIKE is case-insensitive by default. To have it use your index, you
need to either make the index case-insensitive:
CREATE INDEX test_name ON test (name COLLATE NOCASE);
Sorry, tried to create the index this way, but it
still isn't used by the query.
http://www.sqlite.org/optoverview.html#like_opt
Yes, that's precisely the document that led me to believe the
optimization should take place. But it doesn't seem to work for me
either:
CREATE TABLE test (name char);
CREATE INDEX test_name ON test (name COLLATE NOCASE);
explain query plan select * from test where name LIKE 'aaa%';
order from detail
0 0 TABLE test
Igor Tandetnik
-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------