BUG #5102: Silent IN (list of strings) failure to detect syntax error when list is linewrapped

Поиск
Список
Период
Сортировка
От Geoff Tolley
Тема BUG #5102: Silent IN (list of strings) failure to detect syntax error when list is linewrapped
Дата
Msg-id 200910072348.n97NmNIn067659@wwwmaster.postgresql.org
обсуждение исходный текст
Ответы Re: BUG #5102: Silent IN (list of strings) failure to detect syntax error when list is linewrapped  (Alvaro Herrera <alvherre@commandprompt.com>)
Re: BUG #5102: Silent IN (list of strings) failure to detect syntax error when list is linewrapped  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
Список pgsql-bugs
The following bug has been logged online:

Bug reference:      5102
Logged by:          Geoff Tolley
Email address:      geoff.tolley@yougov.com
PostgreSQL version: 8.3.8
Operating system:   Ubuntu 8.04 x86_64
Description:        Silent IN (list of strings) failure to detect syntax
error when list is linewrapped
Details:

I would expect the last of these queries to give the same syntax error as
the penultimate one.  Reproducible on my test instance of 8.4.1 as well:


postgres=# SELECT version();
                                             version
----------------------------------------------------------------------------
---------------------
 PostgreSQL 8.3.8 on x86_64-pc-linux-gnu, compiled by GCC cc (GCC) 4.2.4
(Ubuntu 4.2.4-1ubuntu3)
(1 row)

postgres=# SELECT 'hello' WHERE '1' IN ('1', '2');
 ?column?
----------
 hello
(1 row)

postgres=# SELECT 'hello' WHERE '1' IN ('1' '2');
ERROR:  syntax error at or near "'2'"
LINE 1: SELECT 'hello' WHERE '1' IN ('1' '2');
                                         ^
postgres=# SELECT 'hello' WHERE '1' IN ('1'
postgres(#  '2');
 ?column?
----------
(0 rows)

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

Предыдущее
От: "Herve LEFEBVRE"
Дата:
Сообщение: BUG #5104: tsearch parser mislead
Следующее
От: "Walter Mesz"
Дата:
Сообщение: BUG #5105: "Select Into Strict" does not throw NO_DATA_FOUND