Re: [HACKERS] RFC: Key normalization for nbtree - Mailing list pgsql-hackers

From Greg Stark
Subject Re: [HACKERS] RFC: Key normalization for nbtree
Date
Msg-id CAM-w4HPRrXZY-gMYxPkWPV8QqeEDB3EptW9FtuPiWM=fPB==vg@mail.gmail.com
Whole thread Raw
In response to [HACKERS] RFC: Key normalization for nbtree  (Peter Geoghegan <pg@bowt.ie>)
Responses Re: [HACKERS] RFC: Key normalization for nbtree
List pgsql-hackers
On 10 July 2017 at 19:40, Peter Geoghegan <pg@bowt.ie> wrote:
> Key normalization means creating a representation for internal page
> items that we always just memcmp(), regardless of the details of the
> underlying datatypes.

One thing I would like to see is features like this added to the
opclasses (or opfamilies?) using standard PG functions that return
standard PG data types. So if each opclass had a function that took
the data type in question and returned a bytea then you could
implement that function using a language you felt like (in theory),
test it using standard SQL, and possibly even find other uses for it.
That kind of abstraction would be more promising for the future than
having yet another C api that is used for precisely one purpose and
whose definition is "provide the data needed for this usage".

-- 
greg



pgsql-hackers by date:

Previous
From: Claudio Freire
Date:
Subject: Re: [HACKERS] Vacuum: allow usage of more than 1GB of work mem
Next
From: Greg Stark
Date:
Subject: Re: [HACKERS] New partitioning - some feedback