Search Postgresql Archives

Re: Returning JSON or JSONB

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Tue, Oct 20, 2015 at 4:04 AM, Andreas Kretschmer <akretschmer@xxxxxxxxxxxxx> wrote:
If you are returning JSON, so is JSON the best choice.

The JSONB type represented as text (i.e., when you query it) is valid JSON. The same with JSON data type. The DB server renders the data as text when it sends it to you.

The choice should be made based on what you plant to do with the data in the database and if the properties of JSON are needed vs. the properties of JSONB (specifically duplicate key names and ordering of keys) or if it is not manipulated in the DB ever, then plain text is reasonable too.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux