ALTER COLUMN, trading a DOMAIN for its base datatype
I'm (still) trying to transition out from under the uniqueidentifier
contrib module to the native uuid datatype. I seem to be able to create a
domain for uniqueidentifier:
CREATE DOMAIN public.uniqueidentifier AS uuid;
and then use pg_restore to reload my data without the contrib module.
I'd like for my final step to be to
ALTER TABLE foo ALTER COLUMN my_uuid TYPE uuid;
... Is PostgreSQL smart enough to not have to rewrite the table and simply
shed the domain for the underlying datatype?
C GG <cgg0007@gmail.com> writes:
... Is PostgreSQL smart enough to not have to rewrite the table and simply
shed the domain for the underlying datatype?
Yes, in recent versions ... don't remember how far back exactly.
regards, tom lane
--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general