Re: plpgsql: Is ELSE IF supported or not?

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема Re: plpgsql: Is ELSE IF supported or not?
Дата
Msg-id 162867790806260414h566d25e6ua664413deffe155f@mail.gmail.com
обсуждение исходный текст
Ответ на plpgsql: Is ELSE IF supported or not?  ("Marko Kreen" <markokr@gmail.com>)
Ответы Re: plpgsql: Is ELSE IF supported or not?
Список pgsql-hackers
hello

2008/6/26 Marko Kreen <markokr@gmail.com>:
> Docs seems to say it is, but following function fails to compile:
>
> create function err_else() returns void as $$
> begin
>    if 1 = 1 then
>    else if 1 = 2 then
>    end if;
> end;
> $$ language plpgsql;
>
> ERROR:  syntax error at or near ";"
> LINE 6: end;

use elseif or elsif :)

Pavel

>
> Version 8.3.3.
>
> --
> marko
>
> --
> Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-hackers
>


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

Предыдущее
От: "Marko Kreen"
Дата:
Сообщение: plpgsql: Is ELSE IF supported or not?
Следующее
От: "Marko Kreen"
Дата:
Сообщение: Re: plpgsql: Is ELSE IF supported or not?