Re: [HACKERS] SQL/JSON in PostgreSQL

Поиск
Список
Период
Сортировка
От Piotr Stefaniak
Тема Re: [HACKERS] SQL/JSON in PostgreSQL
Дата
Msg-id AM2PR09MB056384CBFA4F66DDFE1DF230855C0@AM2PR09MB0563.eurprd09.prod.outlook.com
обсуждение исходный текст
Ответ на [HACKERS] SQL/JSON in PostgreSQL  (Oleg Bartunov <obartunov@gmail.com>)
Ответы Re: [HACKERS] SQL/JSON in PostgreSQL
Список pgsql-hackers
On 2017-02-28 20:08, Oleg Bartunov wrote:
> Attached patch is an implementation of SQL/JSON data model from SQL-2016
> standard (ISO/IEC 9075-2:2016(E))

I've faintly started looking into this.

> We created repository for reviewing (ask for write access) -
> https://github.com/postgrespro/sqljson/tree/sqljson

> Examples of usage can be found in src/test/regress/sql/sql_json.sql

> The whole documentation about json support should be reorganized and added,
> and we plan to do this before release. We need help of community here.


> The standard describes SQL/JSON path language, which used by SQL/JSON query
> operators to query JSON. It defines path language as string literal. We
> implemented the path language as  JSONPATH data type, since other
> approaches are not friendly to planner and executor.

I was a bit sad to discover that I can't
PREPARE jsq AS SELECT JSON_QUERY('{}', $1);
I assume because of this part of the updated grammar:
json_path_specification:
    Sconst         { $$ = $1; }
   ;

Would it make sense, fundamentally, to allow variables there? After 
Andrew Gierth's analysis of this grammar problem, I understand that it's 
not reasonable to expect JSON_TABLE() to support variable jsonpaths, but 
maybe it would be feasible for everything else? From Andrew's changes to 
the new grammar (see attached) it seems to me that at least that part is 
possible. Or should I forget about trying to implement the other part?

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Вложения

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [HACKERS] Re: PANIC: invalid index offnum: 186 when processing BRIN indexes in VACUUM
Следующее
От: Nico Williams
Дата:
Сообщение: Re: [HACKERS] MERGE SQL Statement for PG11