Re: Do we need use more meaningful variables to replace 0 in catalog head files?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Do we need use more meaningful variables to replace 0 in catalog head files?
Дата
Msg-id 18677.1479054189@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Do we need use more meaningful variables to replace 0 in catalog head files?  (Andres Freund <andres@anarazel.de>)
Ответы Re: Do we need use more meaningful variables to replace 0 in catalog head files?
Список pgsql-hackers
Andres Freund <andres@anarazel.de> writes:
> On 2016-11-13 00:20:22 -0500, Peter Eisentraut wrote:
>> Then we're not very far away from just using CREATE FUNCTION SQL commands.

> Well, those do a lot of syscache lookups, which in turn do lookups for
> functions...

We can't use CREATE FUNCTION as the representation in the .bki file,
because of the circularities involved (you can't fill pg_proc before
pg_type nor vice versa).  But I think Peter was suggesting that the
input to the bki-generator script could look like CREATE commands.
That's true, but I fear it would greatly increase the complexity
of the script for not much benefit.  It does little for the question of
"how do you update the data when adding a new pg_proc column", for
instance.  And you'd still need some non-SQL warts, like how to specify
manually-assigned OIDs for types and functions.  (I'm not sure whether
we could get away with dropping fixed assignments of function OIDs,
but we absolutely can't do so for types.  Lots of client code knows
that text is oid 25, for example.)
        regards, tom lane



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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Do we need use more meaningful variables to replace 0 in catalog head files?
Следующее
От: Andres Freund
Дата:
Сообщение: Re: Do we need use more meaningful variables to replace 0 in catalog head files?