BUG #12070: hstore extension: hstore_to_json_loose produces invalid JSON

Поиск
Список
Период
Сортировка
От bouda@edookit.com
Тема BUG #12070: hstore extension: hstore_to_json_loose produces invalid JSON
Дата
Msg-id 20141126081059.15510.5034@wrigleys.postgresql.org
обсуждение исходный текст
Ответы Re: BUG #12070: hstore extension: hstore_to_json_loose produces invalid JSON  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-bugs
The following bug has been logged on the website:

Bug reference:      12070
Logged by:          Ondřej Bouda
Email address:      bouda@edookit.com
PostgreSQL version: 9.4beta2
Operating system:   Windows 7 64bit
Description:

The hstore_to_json_loose(hstore) produces an invalid JSON in the following
case:

SELECT hstore_to_json_loose(hstore(ARRAY ['name'], ARRAY ['1.'] :: TEXT
[]))

Output: {"name": 1.}

Expected:
  either {"name": "1."}
  or     {"name": 1}
  (the latter being the preferred one so that it produces the same JSON as
hstore_to_jsonb_loose(hstore))

The actual output is indeed incorrect as JSON does not permit `1.` - it must
be a string.

Tested with PostgreSQL 9.4 RC1 and still wrong.

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

Предыдущее
От: tommaso.sala@cla-it.eu
Дата:
Сообщение: BUG #12053: Strange behavior for numeric types with unspecified precision-scale
Следующее
От: Luciana Campos
Дата:
Сообщение: Fwd: Rocks 6.1.1 with JDBC connection - What should be wrong?