> SELECT * FROM foo WHERE bar::CHAR(1) = 'A'; > SELECT * FROM foo WHERE bar::CHAR(1) = 'B'; > SELECT * FROM foo WHERE bar::CHAR(2) = 'BC'; > SELECT * FROM foo WHERE bar::CHAR(3) = 'ABC'; Dean, thank you. That would be EXCELLENT solution! Can you confirm that in this case Postgres 8.1 can use index created by CREATE TABLE foo ( bar CHAR(10) PRIMARY KEY ); even on non-C locale ? Andrus. ---------------------------(end of broadcast)--------------------------- TIP 1: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to majordomo@xxxxxxxxxxxxxx so that your message can get through to the mailing list cleanly