Collation in Sqlite
select
name
from
persons
where
name = 'foo' COLLATE NOCASE;
This query is case insensitive and will match:
select
name
from
persons
where
like '%foo%' COLLATE NOCASE;
This query is case insensitive and will match:
The pattern case insensitive seems not to work with the glob operator
Example of default collation defined on the column itself
create table persons
(
name text collate nocase
);
Collate can be assigned by default on the table and overwritten on the query.
For the syntax, see