pgsql: JSON generation improvements.
От | Andrew Dunstan |
---|---|
Тема | pgsql: JSON generation improvements. |
Дата | |
Msg-id | E1UEnuZ-0000qG-R8@gemulon.postgresql.org обсуждение исходный текст |
Список | pgsql-committers |
JSON generation improvements. This adds the following: json_agg(anyrecord) -> json to_json(any) -> json hstore_to_json(hstore) -> json (also used as a cast) hstore_to_json_loose(hstore) -> json The last provides heuristic treatment of numbers and booleans. Also, in json generation, if any non-builtin type has a cast to json, that function is used instead of the type's output function. Andrew Dunstan, reviewed by Steve Singer. Catalog version bumped. Branch ------ master Details ------- http://git.postgresql.org/pg/commitdiff/38fb4d978c5bfc377ef979e2595e3472744a3b05 Modified Files -------------- contrib/hstore/expected/hstore.out | 36 ++++ contrib/hstore/hstore--1.1.sql | 13 ++ contrib/hstore/hstore_io.c | 217 ++++++++++++++++++++++++ contrib/hstore/sql/hstore.sql | 12 ++ doc/src/sgml/func.sgml | 48 ++++++ doc/src/sgml/hstore.sgml | 23 +++ src/backend/utils/adt/json.c | 317 +++++++++++++++++++++++++++++++++--- src/include/catalog/catversion.h | 2 +- src/include/catalog/pg_aggregate.h | 3 + src/include/catalog/pg_proc.h | 8 + src/include/utils/json.h | 5 + src/test/regress/expected/json.out | 24 +++ src/test/regress/sql/json.sql | 12 ++ 13 files changed, 699 insertions(+), 21 deletions(-)
В списке pgsql-committers по дате отправления: