Re: JSON in 9.2 - Could we have just one to_json() function
instead of two separate versions ?
From:
Merlin Moncure <mmoncure(at)gmail(dot)com>
To:
Hannu Krosing <hannu(at)2ndquadrant(dot)com>
Cc:
Andrew Dunstan <andrew(at)dunslane(dot)net>, PavelStehule <pavel(dot)stehule(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject:
Re: JSON in 9.2 - Could we have just one to_json() function
instead of two separate versions ?
Date:
2012-05-01 13:18:28
Message-ID:
CAHyXU0w-gZ+bU72Y=bQFwpeogUKQ66vEZd4D2jPjfuswWhDa0A@mail.gmail.com (view raw or flat )
Thread:
2012-05-01 12:02:40 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
2012-05-01 13:18:28 from Merlin Moncure <mmoncure(at)gmail(dot)com>
2012-05-01 15:02:27 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
2012-05-01 15:49:28 from Joey Adams <joeyadams3(dot)14159(at)gmail(dot)com>
2012-05-01 16:05:06 from Merlin Moncure <mmoncure(at)gmail(dot)com>
2012-05-01 16:22:25 from Andrew Dunstan <andrew(at)dunslane(dot)net>
2012-05-01 16:33:10 from Merlin Moncure <mmoncure(at)gmail(dot)com>
2012-05-01 16:54:14 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-05-01 20:16:01 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
2012-05-01 16:56:20 from Joey Adams <joeyadams3(dot)14159(at)gmail(dot)com>
2012-05-01 18:11:52 from Andrew Dunstan <andrew(at)dunslane(dot)net>
2012-05-01 20:54:56 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
2012-05-01 23:11:02 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-05-02 09:29:29 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
2012-05-04 10:39:38 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
2012-05-04 13:52:45 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-05-04 16:30:39 from Andrew Dunstan <andrew(at)dunslane(dot)net>
2012-05-04 16:56:22 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-05-04 17:43:47 from Robert Haas <robertmhaas(at)gmail(dot)com>
2012-05-04 19:44:54 from Hannu Krosing <hannu(at)krosing(dot)net>
2012-05-05 09:06:15 from Peter Eisentraut <peter_e(at)gmx(dot)net>
2012-05-05 09:13:14 from Peter Eisentraut <peter_e(at)gmx(dot)net>
2012-05-04 19:49:56 from Hannu Krosing <hannu(at)krosing(dot)net>
2012-05-04 19:59:03 from Robert Haas <robertmhaas(at)gmail(dot)com>
2012-05-04 20:12:26 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-05-05 06:07:40 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
2012-05-04 20:40:18 from Hannu Krosing <hannu(at)krosing(dot)net>
2012-05-04 21:24:11 from "David Johnston" <polobo(at)yahoo(dot)com>
2012-05-05 06:06:38 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
2012-05-05 15:49:37 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-05-05 09:16:18 from Peter Eisentraut <peter_e(at)gmx(dot)net>
2012-05-05 13:27:14 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
2012-05-01 21:29:12 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
2012-05-01 22:35:02 from "David Johnston" <polobo(at)yahoo(dot)com>
2012-05-02 00:41:14 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
2012-05-02 01:22:55 from David Johnston <polobo(at)yahoo(dot)com>
2012-05-02 08:52:11 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
2012-05-01 16:12:11 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
Lists:
pgsql-hackers
On Tue, May 1, 2012 at 7:02 AM, Hannu Krosing <hannu(at)2ndquadrant(dot)com> wrote:
> Hi hackers
>
> After playing around with array_to_json() and row_to_json() functions a
> bit it I have a question - why do we even have 2 variants *_to_json()
>
> Collapsing array_to_json() and row_to_json() into just to_json()
I asked the same question. It was noted that the xml functions aren't
overloaded like that and that it's cleaner to introduce datum specific
behaviors if you don't overload.
I don't really agree with that or any of the naming styles that are in
the form inputtype_func() but I think most people are on the other
side of the argument.
merlin
In response to
Responses
pgsql-hackers by date
Next :From: Peter GeogheganDate: 2012-05-01 13:19:16
Subject : Re: proposal: additional error fields
Previous :From : Robert HaasDate : 2012-05-01 13:09:36
Subject : Re: Future In-Core Replication