Re: check_function_bodies not doing much
От | David G. Johnston |
---|---|
Тема | Re: check_function_bodies not doing much |
Дата | |
Msg-id | CAKFQuwbWS1u3KZ9sjw9u2h-4y0hSESmAAzf682STpon4OH-NoQ@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: check_function_bodies not doing much (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: check_function_bodies not doing much
|
Список | pgsql-general |
Marcelo Lacerda <marceloslacerda@gmail.com> writes:
> I was trying to get postgres to warn me that I'm referencing a table that
> it doesn't exists inside a function so I was told on the IRC to check the
> setting "check_function_bodies", however when I use it in a plpgsql
> function it doesn't actually check if the tables in the body exist. Is this
> the correct behavior?
Yes. It's supposed to be a syntax check, not a check that the function
would work when executed. (Depending on the particular PL you're using,
which you didn't mention, it might be a pretty weak syntax check too.)
The quoted text includes "however when I use it in a plpgsql function" so we're good there.
Might be worth updating the docs for the GUC (or a note in the languages themselves) to mention what the check covers for each of them. At least distinguishing between syntax and semantics for each.
David J.
В списке pgsql-general по дате отправления: