Re: pg_migrator and an 8.3-compatible tsvector data type

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: Josh Berkus <josh(at)agliodbs(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>, Oleg Bartunov <oleg(at)sai(dot)msu(dot)su>, Teodor Sigaev <teodor(at)sigaev(dot)ru>
Subject: Re: pg_migrator and an 8.3-compatible tsvector data type
Date: 2009-05-30 15:33:45
Message-ID: 9356.1243697625@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Bruce Momjian <bruce(at)momjian(dot)us> writes:
> I have discovered a simpler solution using ALTER TABLE and calling a
> conversion function:

> test=> CREATE TABLE tsvector_test(x tsvector);
> CREATE TABLE
> test=> ALTER TABLE tsvector_test ALTER COLUMN x TYPE tsvector
> test-> USING conversion_func(x);
> ALTER TABLE

> No need for a fake data type and the required index infrastructure.

I think this is basically a large-caliber foot gun. You're going to
pretend that invalid data is valid, until the user gets around to fixing
it?

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Simon Riggs 2009-05-30 16:51:35 Re: Clean shutdown and warm standby
Previous Message Dimitri Fontaine 2009-05-30 14:12:48 Re: pg_migrator and an 8.3-compatible tsvector data type