>>>>> "Marti" == Marti Raudsepp <[email protected]> writes:
>> (yaml format)
>> Grouping Sets:
>> - - "two"
>> - "four"
>> - - "two"
>> -
Marti> Now this is weird.
You're telling me. Also, feeding it to an online yaml-to-json
converter gives the result as [["two","four"],["two"],null] which is
not quite the same as the json version. An alternative would be:
Grouping Sets:
- - "two"
- "four"
- - "two"
- []
or
Grouping Sets:
-
- "two"
- "four"
-
- "two"
- []
though I haven't managed to get that second one to work yet.
Marti> But is anyone actually using YAML output format, or was it
Marti> implemented simply "because we can"?
Until someone decides to dike it out, I think we are obligated to make
it produce something resembling correct output.
Marti> The reason I bring this up is that queries are frequently
Marti> dynamically generated by programs.
Good point.
>> would you want the original syntax preserved in views
Marti> Doesn't matter IMO.
I think it's fairly consistent for the parser to do this, since we do
a number of other normalization steps there (removing excess nesting
and so on). This turns out to be quite trivial.
--
Andrew (irc:RhodiumToad)
--
Sent via pgsql-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers