Re: polymorphic arguments and return type for PL/pgSQL - Mailing list pgsql-patches

From Joe Conway
Subject Re: polymorphic arguments and return type for PL/pgSQL
Date
Msg-id 3F00842F.4010508@joeconway.com
Whole thread Raw
In response to Re: polymorphic arguments and return type for PL/pgSQL  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-patches
Tom Lane wrote:
> The latter.  By the time you pay the price of a hash lookup, a slightly
> longer key is nearly free.  (Maybe entirely free, since it might produce
> better-distributed hash values.)

OK -- I figured that's what you'd say, so I've already started down that
road.

> dynahash only supports fixed-length keys, so don't forget to zero out
> unused positions in the argument type vector.

Important safety tip! Thanks.

> BTW, I can't see any need to include the return type in the hash key ---
> wouldn't it be predetermined given the argument types?

Yup, very true.

Thanks,

Joe


pgsql-patches by date:

Previous
From: Tom Lane
Date:
Subject: Re: polymorphic arguments and return type for PL/pgSQL
Next
From: Tom Lane
Date:
Subject: Re: [HACKERS] Missing array support