Re: erroneous restore into pg_catalog schema
| От | Tom Lane |
|---|---|
| Тема | Re: erroneous restore into pg_catalog schema |
| Дата | |
| Msg-id | 14601.1367851053@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Re: erroneous restore into pg_catalog schema (Dimitri Fontaine <dimitri@2ndQuadrant.fr>) |
| Ответы |
Re: erroneous restore into pg_catalog schema
|
| Список | pgsql-hackers |
Dimitri Fontaine <dimitri@2ndQuadrant.fr> writes:
> Tom Lane <tgl@sss.pgh.pa.us> writes:
>> it seems like the extensions code should test for and reject an attempt
>> to set a relocatable extension's schema to pg_catalog. Otherwise you'd
>> be likely to get not-too-intelligible errors from the extension script.
> Reading the code now, it seems to me that we lack a more general test
> and error situation to match with the comments.
> else if (control->schema != NULL)
> {
> /*
> * The extension is not relocatable and the author gave us a schema
> * for it. We create the schema here if it does not already exist.
> */
> We should probably error out when entering in that block of code if the
> extension is relocatable at all, right? That would fix the pg_catalog
> case as well as the general one.
Huh? According to the comment, at least, we don't get here for a
relocatable extension. I don't see anything wrong with auto-creating
the target schema for a non-relocatable extension.
regards, tom lane
В списке pgsql-hackers по дате отправления: