Re: [HACKERS] LONG - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [HACKERS] LONG
Date
Msg-id 7598.945055422@sss.pgh.pa.us
Whole thread Raw
In response to Re: [HACKERS] LONG  (wieck@debis.com (Jan Wieck))
List pgsql-hackers
wieck@debis.com (Jan Wieck) writes:
>> I liked Hiroshi's idea of allowing long values in an index by just
>> pointing to the long table.  Seems that would work too.  varlena access
>> routines make that possible.

>     Maybe possible, but not that good IMHO. Would  cause  another
>     index  scan from inside index scan to get at the value. An we
>     all agree that indexing huge values isn't that a  good  thing
>     at all.

Well, no, you shouldn't make indexes on fields that are usually big.
But it'd be awfully nice if the system could cope with indexing fields
that just had a long value once in a while.  Right now, our answer is
to refuse to let you insert a long value into an indexed field; I don't
think that's very satisfactory.

What do you think of my idea of not using any index on the expansion
table at all, but instead having the primary tuple reference the
expansion tuples via their CTIDs?  More work at VACUUM time, for sure,
but a lot less work elsewhere.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [HACKERS] generic LONG VARLENA
Next
From: Bruce Momjian
Date:
Subject: Re: [HACKERS] LONG