Hi, List! kosten=# select version(); version --------------------------------------------------------------------------- PostgreSQL 8.0.0rc5 on i686-pc-linux-gnu, compiled by GCC gcc (GCC) 3.2.3 (1 row) kosten=# create table foo(t bit(4)); CREATE TABLE kosten=# insert into foo values(B'0011'); INSERT 985996 1 kosten=# select t from foo; t ------ 0011 (1 row) But if I do something like this: kosten=# select t::text from foo; ERROR: cannot cast type bit to text I get an error. Okay the system cannot cast bit to text... But this is the big problem for me... Is there a way to cast bit(n) to text or varchar? thanks in advance. Sergey Karin PS. I have found that there are some functions: varbit_in() and varbit_out(). But they works with internal type cstring. And I cannot cast cstring to varchar or text. ---------------------------(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