postgresql_16:9.6.10.2 How to Use It
PostgreSQL 16 > Appendixes > Additional Supplied Modules and Extensions > citext — a case-insensitive character string type > How to Use It
Here's a simple example of usage: CREATE TABLE users ( nick CITEXT PRIMARY KEY, pass TEXT NOT NULL ); INSERT INTO users VALUES ( 'larry', sha256(random()::text::bytea) ); INSERT INTO users VALUES ( 'Tom', sha256(random()::text::bytea) ); INSERT INTO users VALUES ( 'Damian', sha256(random()::text::bytea) ); INSERT INTO users VALUES ( 'NEAL', sha256(random()::text::bytea) ); INSERT INTO users VALUES ( 'Bjørn', sha256(random()::text::bytea) ); SELECT * FROM users WHERE nick = 'Larry'; The SELECT statement will return one tuple, even though the nick column was set to larry and the query was for Larry.