Re: Add jsonb_compact(...) for whitespace-free jsonb to text

From: Jim Nasby <Jim(dot)Nasby(at)BlueTreble(dot)com>
To: "Shulgin, Oleksandr" <oleksandr(dot)shulgin(at)zalando(dot)de>, Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>, Ryan Pedela <rpedela(at)datalanche(dot)com>, Stephen Frost <sfrost(at)snowman(dot)net>, Sehrope Sarkuni <sehrope(at)jackdb(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Add jsonb_compact(...) for whitespace-free jsonb to text
Date: 2016-05-11 13:40:28
Message-ID: 9def5342-0ae7-8211-4823-ebde596e6211@BlueTreble.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 4/29/16 8:56 AM, Shulgin, Oleksandr wrote:
> It would probably make sense model this function after Python's
> "dump-to-JSON-string"
> function: https://docs.python.org/2/library/json.html#json.dumps With
> the optional parameters for sorting the keys, indentation size and
> punctuation. This way all the prettiness enhancements could be
> contained in a single function w/o the need for generalized interface
> used in many places.

+1. I've found the output functions of json.dumps to be very handy.
--
Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
Experts in Analytics, Data Architecture and PostgreSQL
Data in Trouble? Get it in Treble! http://BlueTreble.com
855-TREBLE2 (855-873-2532) mobile: 512-569-9461

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2016-05-11 13:56:04 Re: asynchronous and vectorized execution
Previous Message Peter Eisentraut 2016-05-11 13:40:09 Re: ALTER TABLE lock downgrades have broken pg_upgrade