From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | Bruce Momjian <bruce(at)momjian(dot)us> |
Cc: | 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-28 21:26:20 |
Message-ID: | 200905282126.n4SLQK105812@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Because no one has responed
---------------------------------------------------------------------------
Bruce Momjian wrote:
> I found out at PGCon that the internal format of tsvector changed
> slightly from 8.3 to 8.4. Teodor gave me a conversion function and I
> have adjusted pg_migrator to install a v8_3_tsvector data type to be
> used during the load so the old user tables use that data type. You can
> see the code here at the bottom of this file:
>
> http://cvs.pgfoundry.org/cgi-bin/cvsweb.cgi/pg-migrator/pg_migrator/src/pg_migrator.c?rev=1.36&content-type=text/x-cvsweb-markup
>
> I am not done yet because eventually v8_3_tsvector will be moved into a
> separate schema and the tsvector data type restored.
>
> The problem I have is that while I have created v8_3_tsvector (with
> casts), I have not created index routines for it, so I get this error
> when restoring a database that uses a GIN index on tsvector:
>
> Restoring database schema
> psql:/u/postgres/pg_migrator_dump_db.sql:7006: ERROR: data type
> tsvector has no default operator class for access method "gin"
> HINT: You must specify an operator class for the index or define a
> default operator class for the data type.
>
> So, how do I create a compatible set of hooks for v8_3_tsvector?
> Because tsvector is a native data type I can't figure out how to set up
> a similar type. Also, will the indexes be OK if they are created from
> types that don't have the 8.3 format? What about new indexes created
> after the migration is done?
>
> Ideally the cast would just be called during index activity and the 8.4
> tsvector index routines used. I am told by Teodor that GiST indexes
> would be fine with the 8.3 data format, and we are forcing the
> reindexing of GIN indexes anyway in 8.4.
>
> --
> Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
> EnterpriseDB http://enterprisedb.com
>
> + If your life is a hard drive, Christ can be your backup. +
>
> --
> Sent via pgsql-hackers mailing list (pgsql-hackers(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-hackers
--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com
+ If your life is a hard drive, Christ can be your backup. +
From | Date | Subject | |
---|---|---|---|
Next Message | David E. Wheeler | 2009-05-28 21:26:55 | Re: search_path vs extensions |
Previous Message | David E. Wheeler | 2009-05-28 21:24:37 | Re: search_path vs extensions |