Re: Why does the PL/pgSQL compiler do this?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Why does the PL/pgSQL compiler do this?
Дата
Msg-id 20520.1477967933@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Why does the PL/pgSQL compiler do this?  (Michael Moore <michaeljmoore@gmail.com>)
Ответы Re: Why does the PL/pgSQL compiler do this?
Список pgsql-sql
Michael Moore <michaeljmoore@gmail.com> writes:
> I'm still a bit confused. If I replace the ROLLBACK; command with ELEPHANT;
> the result is a syntax error. Why doesn't ROLLBACK; produce the same error
> since it is not valid in the LANGUAGE plpgsql.

That's a runtime error so far as plpgsql is concerned, because it relies
on the SPI layer to throw the error.  It might be practical to complain
about it at compile time, but it would be some extra code that nobody's
written.
        regards, tom lane



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

Предыдущее
От: Adrian Klaver
Дата:
Сообщение: Re: Why does the PL/pgSQL compiler do this?
Следующее
От: Michael Moore
Дата:
Сообщение: Re: Why does the PL/pgSQL compiler do this?