change serialization of array() aggregate to JSON and cast CSV fields to text
change serialization of array() aggregate to JSON and cast CSV fields to text

WARNING: might affect compatibility with existing clients that relied
on buggy behavior.

Now, use of the array(x) function in the /aggregate/ or
/attributegroup/ APIs will generate a JSON-encoded array of the chosen
column or sub-record x.  In a JSON result representation, this JSON
array will be embedded as the field value, i.e. the value will look
like a native JSON array within the enclosing object.  In a CSV result
representation, the value will be a text string containing the JSON
array representation.

Use of the sub-record notation will generate a JSON-encoded object of
the chosen sub-record.  In a JSON result representation, this JSON
sub-record will be embedded as the field value, i.e. the value will
look like a native JSON object within the enclosing object or array.
In a CSV result representation, the value will be a text string
containing the JSON object representation.

Previously, PostgreSQL serializations of arrays and JSON leaked out
into other representations, generating strange mixtures of different
quotes, escapes, and array punctuation.



informatics-isi-edu/ermrest,ini-bdds/ermrest,informatics-isi-edu/ermrest,ini-bdds/ermrest