Re: Should I use JSON?

From: Tim Cross <theophilusx(at)gmail(dot)com>
To: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: Should I use JSON?
Date: 2020-05-21 23:48:59
Message-ID: 87pnawrgr8.fsf@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


stan <stanb(at)panix(dot)com> writes:

> Worming on a small project, and have been doing a lot of Perl scripting to
> parse various types of files to populate the database. Now I need to get
> data from a cloud services provider (time-keeping). They have a REST API
> that returns data in a JSOSN format.
>
> So here is the question, should I just manually parse this data, as I have
> been doing to insert into appropriate entities into the database? Or should I
> insert the JSON data, and use some queries in the database to populate my
> tables from the JSON tables?

Given you plan to store your data in 'normal' tables and you are already
using a scripting language to get the data from the remote API
and your already processing data in various forms using Perl, I
would not bother. All you will really do is add another layer of
complexity and skill requirement (i.e. JSON in the database and writing
JSON queries using PG's SQL JSON support).

--
Tim Cross

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Thomas Munro 2020-05-22 00:19:37 Re: Help understanding SIReadLock growing without bound on completed transaction
Previous Message Tom Lane 2020-05-21 23:36:01 Re: Query returns no rows in pg_basebackup cluster