Search Postgresql Archives

In-place conversion of type bool

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I am converting a database to PostgreSQL. I use ODBC to create the
PostgreSQL database and copy the data.

The database says that it's bool implementation is char(1), just as
PostgreSQL does. I can copy te data OK, but I would like to change the
actual type of the column from char(1) to bool. Is that possible without
copying the column to a temporary column, dropping the old column and
renaming the temporary columns to the old column? 

I also have another table that has mac addresses stored *exactly* in the
same format as PostgreSQL macaddr type that are used as primary key and
dropping that key would mean a major headache. In this case I would like
to be able to change the type from varchar to macaddr.

TIA


-- 
Groeten,

Joost Kraaijeveld
Askesis B.V.
Molukkenstraat 14
6524NB Nijmegen
tel: 024-3888063 / 06-51855277
fax: 024-3608416
web: www.askesis.nl



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux