Re: [python-sql] arrays and json with python-sql

2017-09-08 Thread Richard PALO
Le 07/09/2017 à 19:12, Cédric Krier a écrit : ARRAY_AGG does not seem to be in any SQL standard, so it is not implemented in python-sql. But it is very simple to create it: from sql.aggregate import Aggregate class ArrayAgg(Aggregate): __slots__ = () _sql = 'ARRAY_AG

Re: [python-sql] arrays and json with python-sql

2017-09-07 Thread Cédric Krier
On 2017-09-07 18:13, Richard PALO wrote: > Is there any hints on how to use (if supported) the postgresql json array > support? > > I'm a bit at a loss as to how to approach translating something like the > following > to python/sql getting a dictionary list appended to each returned row: > > >

[python-sql] arrays and json with python-sql

2017-09-07 Thread Richard PALO
Is there any hints on how to use (if supported) the postgresql json array support? I'm a bit at a loss as to how to approach translating something like the following to python/sql getting a dictionary list appended to each returned row: select fy.id, fy.name, fy.date_start, fy.date_stop,