Re: RFD: schemas and different kinds of Postgres objects

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: RFD: schemas and different kinds of Postgres objects
Дата
Msg-id Pine.LNX.4.30.0201240003120.686-100000@peter.localdomain
обсуждение исходный текст
Ответ на Re: RFD: schemas and different kinds of Postgres objects  (Bill Studenmund <wrstuden@netbsd.org>)
Ответы Re: RFD: schemas and different kinds of Postgres objects
Список pgsql-hackers
Bill Studenmund writes:

> Does SQL'99 say anything about this?

Yes, though, as usual, you have to twist your brain a little to understand
it.  My understanding is that for a function call of the form "foo(a, b)"
it goes like this:

1. Find all functions named "foo" in the current database.  This is the
set of "possibly candidate routines".

2. Drop all routines that you do not have EXECUTE privilege for.  This is
the set of "executable routines".

3. Drop all routines that do not have compatible parameter lists.  This is
the set of "invocable routines".

4. Drop all routines whose schema is not in the path.  This is the set of
"candidate routines".

5. If you have more than one routine left, eliminate some routines
according to type precedence rules.  (We do some form of this, SQL99
specifies something different.)  This yields the set of "candidate subject
routines".

6. Choose the routine whose schema is earliest in the path as the "subject
routine".

Execute the subject routine.  Phew!


This doesn't look glaringly wrong to me, so maybe you want to consider it.
Please note step 2.

-- 
Peter Eisentraut   peter_e@gmx.net



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

Предыдущее
От: "Christopher Kings-Lynne"
Дата:
Сообщение: Re: Query taking a long time...
Следующее
От: Teodor Sigaev
Дата:
Сообщение: Re: Checking for undefined in Perl interface code?