Re: PostgreSQL::PLPerl::Call - Simple interface for calling SQL functions from PostgreSQL PL/Perl - Mailing list pgsql-hackers

From Tom Lane
Subject Re: PostgreSQL::PLPerl::Call - Simple interface for calling SQL functions from PostgreSQL PL/Perl
Date
Msg-id 18657.1266361294@sss.pgh.pa.us
Whole thread Raw
In response to Re: PostgreSQL::PLPerl::Call - Simple interface for calling SQL functions from PostgreSQL PL/Perl  (Martijn van Oosterhout <kleptog@svana.org>)
List pgsql-hackers
Martijn van Oosterhout <kleptog@svana.org> writes:
> On Tue, Feb 16, 2010 at 09:11:24AM -0800, David E. Wheeler wrote:
>>> An extra source of puzzlement is that the oid of the 'unknown' type is
>>> 705 not 0, and the unknown type isn't discussed in the docs (as far as I
>>> could see).
>> 
>> Yes, I noticed that, too. Greg, do you know the answer to that?

> My guess is that, semantically, 0 means the datatype is unknown,
> whereas 705 means the datatype is known to be type "unknown".

I think the reason the client-side docs recommend using zero is to avoid
having clients know about the unknown type explicitly (in particular, to
discourage people from hardwiring "705" into their code).  AFAIR there's
not a lot of difference in terms of what the parser will do with it.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Chris Browne
Date:
Subject: Re: LISTEN/NOTIFY and notification timing guarantees
Next
From: Josh Berkus
Date:
Subject: Re: OpenVMS?