Re: [HACKERS] RFC - change of behaviour of pg_get_userbyid & pg_get_viewdef?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [HACKERS] RFC - change of behaviour of pg_get_userbyid & pg_get_viewdef?
Дата
Msg-id 15367.969836545@sss.pgh.pa.us
обсуждение исходный текст
Ответ на RFC - change of behaviour of pg_get_userbyid & pg_get_viewdef?  (Philip Warner <pjw@rhyme.com.au>)
Список pgsql-sql
Philip Warner <pjw@rhyme.com.au> writes:
> 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.

I don't believe it's practical to trap errors and return a NULL for
broken views.  Moreover, I do not think it's a good idea to respond
to client errors (invalid view name) the same as database problems
(broken views).  So, I agree with the part of the proposal that says
to return NULL instead of 'Not a view' when there is no view by the
given name, but I do not agree with trying to suppress errors due to
metadata problems.

            regards, tom lane

В списке pgsql-sql по дате отправления:

Предыдущее
От: Stephan Szabo
Дата:
Сообщение: Re: Select between two databases
Следующее
От: Philip Warner
Дата:
Сообщение: Re: [HACKERS] RFC - change of behaviour of pg_get_userbyid & pg_get_viewdef?