potential bug in error message in with clause

Поиск
Список
Период
Сортировка
От Szymon Guz
Тема potential bug in error message in with clause
Дата
Msg-id CAFjNrYsjzd3SCsNzrg9tywwXDX6thNqwvagBBkQCc9OP8ur3dw@mail.gmail.com
обсуждение исходный текст
Ответы Re: potential bug in error message in with clause  (Albe Laurenz <laurenz.albe@wien.gv.at>)
Список pgsql-hackers
Hi,
today on IRC there was a strange problem shown. The small working example looks like this:

x=# with x as (insert into a(t) values('1') returning *) select * from x;
 t 
---
 1
(1 row)

x=# with x (insert into a(t) values('1') returning *) select * from x;
ERROR:  syntax error at or near "into"
LINE 1: with x (insert into a(t) values('1') returning *) select * f...
                       ^

The initial code was run on 9.2; I've checked that on 9.4devel.

The error message is really not useful, as there is missing "as" after "with x". There is no problem with "into".

regards
Szymon

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

Предыдущее
От: KONDO Mitsumasa
Дата:
Сообщение: Re: Design proposal: fsync absorb linear slider
Следующее
От: Andrew Tipton
Дата:
Сообщение: Add json_typeof() and json_is_*() functions.