Re: Should I use JSON?

Поиск
Список
Период
Сортировка
От David G. Johnston
Тема Re: Should I use JSON?
Дата
Msg-id CAKFQuwbWTQL-tycmzH-0=9iC1oTyuMu0gZPO=xw=ciA=7fNapQ@mail.gmail.com
обсуждение исходный текст
Ответ на Should I use JSON?  (stan <stanb@panix.com>)
Список pgsql-general
On Thu, May 21, 2020 at 8:37 AM stan <stanb@panix.com> wrote:
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?

The simplest thing that works is usually a good starting point.

I consider it a requirement that I can get to the original data as supplied by the vendor.  So, if you are capturing that elsewhere, going directly to structured tables is sufficient.  If you don't have any other place where that gets saved I would save it to a table first then convert it to the final structured tables.

My current setup is using "jq" to perform an intermediate transform of the source json to table-specific files and then using psql and jsonb_to_record insert the json data into the tables.

David J.

В списке pgsql-general по дате отправления:

Предыдущее
От: Israel Brewster
Дата:
Сообщение: Re: Table partitioning for cloud service?
Следующее
От: Adrian Klaver
Дата:
Сообщение: Re: Table partitioning for cloud service?