Re: tsearch2() trigger and domain types... - Mailing list pgsql-sql

From manchicken
Subject Re: tsearch2() trigger and domain types...
Date
Msg-id 200706190855.47398.manchicken@notsosoft.net
Whole thread Raw
In response to Re: tsearch2() trigger and domain types...  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: tsearch2() trigger and domain types...
List pgsql-sql
On Monday 18 June 2007 17:59:50 Tom Lane wrote:
> "Michael D. Stemle, Jr." <manchicken@notsosoft.net> writes:
> > For standardization in my database I use a domain (login_t) for my login
> > column in my profile table.
> >
> > Well, here's what I get upon every update and insert to the profile
> > table: WARNING:  TSearch: 'login' is not of character type
>
> The tsearch trigger seems to insist that the column be text, varchar(n),
> or char(n) ... no domains need apply :-(
>
> I'm not real sure why it doesn't just invoke the column's output
> function and be datatype-agnostic.  Or at least do that when the
> shortcut "I know what text looks like" path isn't applicable.

Is there any way to cast these column datatypes in the trigger to fool it, or 
is the only way to fix this to reconstruct the table without domains?  I'd 
really prefer not to abandon domains if at all possible.

-- 
~ manchicken <><
(A)bort, (R)etry, (I)nfluence with large hammer.
09 F9 11 02 9D 74 E3 5B D8 41 56 C5 63 56 88 C0


Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html


pgsql-sql by date:

Previous
From: Ranieri Mazili
Date:
Subject: Subquery problems
Next
From: Tom Lane
Date:
Subject: Re: tsearch2() trigger and domain types...