RFC - change of behaviour of pg_get_userbyid & pg_get_viewdef? - Mailing list pgsql-sql

From Philip Warner
Subject RFC - change of behaviour of pg_get_userbyid & pg_get_viewdef?
Date
Msg-id 3.0.5.32.20000924131555.02807820@mail.rhyme.com.au
Whole thread Raw
Responses Re: [HACKERS] RFC - change of behaviour of pg_get_userbyid & pg_get_viewdef?  (Tom Lane <tgl@sss.pgh.pa.us>)
Change of behaviour of pg_get_userbyid & pg_get_viewdef - do it?  (Philip Warner <pjw@rhyme.com.au>)
List pgsql-sql
Two routines do eccentric things when they can't find required supporting
data:

pg_get_userbyid

    returns 'unknown (UID=<uid-number>)' when the UID does not exist.

pg_get_viewdef

    returns 'Not a view' when passed a non-existant or non-view table
    it also signals errors when the underlying metadata can not be found.

The proposal is to return NULL in the above cases - in the final case,
probably also generate a NOTICE.

Does anybody have a problem with this? Think it's a bad idea etc?



----------------------------------------------------------------
Philip Warner                    |     __---_____
Albatross Consulting Pty. Ltd.   |----/       -  \
(A.B.N. 75 008 659 498)          |          /(@)   ______---_
Tel: (+61) 0500 83 82 81         |                 _________  \
Fax: (+61) 0500 83 82 82         |                 ___________ |
Http://www.rhyme.com.au          |                /           \|
                                 |    --________--
PGP key available upon request,  |  /
and from pgp5.ai.mit.edu:11371   |/

pgsql-sql by date:

Previous
From: Jeff MacDonald
Date:
Subject: Re: select
Next
From: Indraneel Majumdar
Date:
Subject: Select between two databases