Re: Forbid to DROP temp tables of other sessions
| От | Daniil Davydov |
|---|---|
| Тема | Re: Forbid to DROP temp tables of other sessions |
| Дата | |
| Msg-id | CAJDiXghu=esq2Gdi522pBQ8DLR6JADKVQG8tNYGXaRXcBDDSyw@mail.gmail.com обсуждение исходный текст |
| Ответ на | Re: Forbid to DROP temp tables of other sessions (Steven Niu <niushiji@gmail.com>) |
| Ответы |
Re: Forbid to DROP temp tables of other sessions
|
| Список | pgsql-hackers |
Hi, On Mon, Mar 17, 2025 at 5:33 PM Steven Niu <niushiji@gmail.com> wrote: > > I mean RangeVarGetRelidExtended(), you deleted the following code: > > if (!OidIsValid(myTempNamespace)) > relId = InvalidOid; /* this probably can't happen? */ Hm, I got it. Let's start with the fact that the comment "this probably can't happen?" is incorrect. Even if we don't have a temporary namespace in our session, we still can specify "pg_temp_N" in the psql query. Next, if relation->schemaname is pg_temp, then we firstly call LookupExplicitNamespace, where you can find if (!OidIsValid(myTempNamespace)) check. -- Best regards, Daniil Davydov
В списке pgsql-hackers по дате отправления: