Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WCtxv-0002Vm-3Q for pgsql-bugs@arkaria.postgresql.org; Mon, 10 Feb 2014 16:44:15 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1WCtxu-00015k-FJ for pgsql-bugs@arkaria.postgresql.org; Mon, 10 Feb 2014 16:44:14 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WCtxt-00015e-TQ for pgsql-bugs@postgresql.org; Mon, 10 Feb 2014 16:44:13 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WCtxr-000394-IJ for pgsql-bugs@postgresql.org; Mon, 10 Feb 2014 16:44:13 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id s1AGi6Md012719; Mon, 10 Feb 2014 11:44:06 -0500 From: Tom Lane To: garyjob@krake.io cc: pgsql-bugs@postgresql.org Subject: Re: BUG #9168: Invalid JSON output generated by SQL statement In-reply-to: <20140210081933.2710.73542@wrigleys.postgresql.org> References: <20140210081933.2710.73542@wrigleys.postgresql.org> Comments: In-reply-to garyjob@krake.io message dated "Mon, 10 Feb 2014 08:19:33 +0000" Date: Mon, 10 Feb 2014 11:44:06 -0500 Message-ID: <12718.1392050646@sss.pgh.pa.us> X-Pg-Spam-Score: -2.5 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org garyjob@krake.io writes: > The invalid JSON output > [{ > "drug bank":"cache \\"that stuff", > "pingedAt":"2014-02-09 16:10:28-08" > },{ > "drug bank":"cache \\"that stuff", > "pingedAt":"2014-02-10 00:10:28-08" > }] > The final JSON output is not valid. Hmm, I can't claim to have memorized the JSON spec, but that looks generally sane to me. What do you think is invalid about it, exactly? (If you're complaining about the backslash having been doubled, that's an effect of the COPY, not a bug in the JSON output function.) regards, tom lane -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs