Re: Views, views, views! (long)

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Views, views, views! (long)
Дата
Msg-id 26116.1115755130@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Views, views, views! (long)  ("Jim C. Nasby" <decibel@decibel.org>)
Ответы Re: Views, views, views! (long)  (Josh Berkus <josh@agliodbs.com>)
Список pgsql-hackers
"Jim C. Nasby" <decibel@decibel.org> writes:
> On Tue, May 10, 2005 at 04:55:40PM +0200, Peter Eisentraut wrote:
>> PostgreSQL does not really distinguish between "system" and "user" things.  
>> How will you do that?

> It's currently done using this function:

> create or replace function _pg_sv_system_schema(name) returns boolean
>   as 'select $1 in (name ''pg_catalog'', name ''pg_toast'',
>                     name ''pg_sysviews'', name ''information_schema'')'
>   language sql immutable strict;

> Objects that are in one of those schemas are considered system objects.
> This is how pg_dump does it

Peter's point still stands though: the *system* isn't making that
distinction.  pg_dump needs to make a distinction so that it doesn't
dump built-in objects; which is not necessarily the same distinction
that a user might want to make.  Thus, the fact that psql does it a
bit differently isn't necessarily a bug.

I think the real problem here is that it's hard to be all things to all
people.  If you suppress display of certain objects, that may be nice
suppression of clutter for one user, yet render the view useless from
the perspective of another user --- or even the same user on a different
day, when he is looking for a particular built-in function for instance.
(I know it's always bugged the heck out of me that \df editorializes on
which functions it thinks I want to see.)
        regards, tom lane


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

Предыдущее
От: Thomas Hallgren
Дата:
Сообщение: Re: Oracle Style packages on postgres
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: Oracle Style packages on postgres