Re: Bug in pg_describe_object, patch v2

Поиск
Список
Период
Сортировка
От Joel Jacobson
Тема Re: Bug in pg_describe_object, patch v2
Дата
Msg-id AANLkTi=7-e1z3hxruiiQjUPrw9Ykx4=51rBnSVtKOqkS@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Bug in pg_describe_object, patch v2  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
2011/1/17 Tom Lane <tgl@sss.pgh.pa.us>:
> Joel Jacobson <joel@gluefinance.com> writes:
>> a) pg_describe_object should always include the schema in the name,
>> even for object in public and pg_catalog.
>
> I knew you were going to demand that next, as soon as you figured out
> that it was an obstacle for using pg_describe_object output as a
> globally unique identifier.  But I'm going to reply, once again, that
> pg_describe_object is not meant to guarantee that and we're not going to
> make it so.

I knew you were going to say that, but I'm going to ask, once again,
is it possible to introduce another function, possibly returning a
differently formatted string, perhaps in JSON, or any other structured
format, suitable to be parsed by an application and which keys are
sorted in a way which guarantees uniqueness? Perhaps it could be named
pg_get_object_identifier or something like that.

It's a huge limitation when designing the type of application I'm
designing, when you need to invent your own solution to the problem,
to avoid the dependency on oids, which are not possible to use across
different databases.

Perhaps I'm the only one working with a project where a unique
identifier for each object is an absolute requirement, but it sounds
unlikely, quite a lot of developers must have thought about these
things before.

--
Best regards,

Joel Jacobson
Glue Finance


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: We need to log aborted autovacuums
Следующее
От: Jeff Davis
Дата:
Сообщение: Re: WIP: RangeTypes