BUG #12792: I can do a SELECT with no fields

Поиск
Список
Период
Сортировка
От lr@pcorp.us
Тема BUG #12792: I can do a SELECT with no fields
Дата
Msg-id 20150220150844.8729.17005@wrigleys.postgresql.org
обсуждение исходный текст
Ответы Re: BUG #12792: I can do a SELECT with no fields
Re: BUG #12792: I can do a SELECT with no fields
Список pgsql-bugs
The following bug has been logged on the website:

Bug reference:      12792
Logged by:          Regina Obe
Email address:      lr@pcorp.us
PostgreSQL version: 9.4.1
Operating system:   Windows 2008 R2
Description:

I'm not sure if this is a bug or not, but it seems like a misfeature if it
isn't.

I made the typo of doing

SELECT FROM sometable;

you can also trigger the issue with just doing:

SELECT ;

outputs:
--
(1 row)

I thought there was something wrong with my viewer since it clearly showed
rows, but no fields.

In 9.3 -- this would just error out as I think most databases do.  So this
was a bit of a gotcha.

I'm not sure if this issue existed in 9.4.0 alreadyy since I've already
upgraded my database.

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

Предыдущее
От: Andrew Gierth
Дата:
Сообщение: Re: BUG #12789: Views defined with VALUES lose their column names when dumped
Следующее
От: Tom Lane
Дата:
Сообщение: Re: BUG #12792: I can do a SELECT with no fields