Re: Passing arguments to views

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Passing arguments to views
Дата
Msg-id 27833.1138990042@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Passing arguments to views  (Chris Campbell <chris@bignerdranch.com>)
Список pgsql-hackers
Chris Campbell <chris@bignerdranch.com> writes:
> I'm fine with those limitations. I can confirm that all of my  
> functions are not referencing tables that don't exist by doing a  
> CREATE OR REPLACE FUNCTION to reload each function. A pg_dump/ 
> pg_restore would accomplish this, but it would be nice to have a  
> "RELOAD FUNCTION" (or "REPARSE"? or "VERIFY"?) command that would  
> just re-parse the function's source code (like CREATE FUNCTION does)  
> and spit out errors if the function is referencing relations that  
> don't exist.

This is putting way too much trust in the behavior of a
PL-language-specific verifier function.  Anyway, you can do what you
want today:select fmgr_sql_validator(oid) from pg_proc where prolang = 14;
(Generalizing this to work for any language is left as an exercise
for the reader...)
        regards, tom lane


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

Предыдущее
От: Chris Campbell
Дата:
Сообщение: Re: Passing arguments to views
Следующее
От: Josh Berkus
Дата:
Сообщение: Re: Multiple logical databases