pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Bruce Momjian <bruce@momjian.us>
To: Wells Oliver <wells.oliver@gmail.com>
Cc: pgsql-admin <pgsql-admin@postgresql.org>
Subject: Re: More efficient access of JSON array elements?
Date: Wed, 22 Jul 2020 14:42:25 -0400
Message-ID: <20200722184225.GD3899@momjian.us> (raw)
In-Reply-To: <CAOC+FBXgTnmVE24uvG4FyFiXCnRxp2p0FTkx9fpoDZc4N6D27w@mail.gmail.com>
References: <CAOC+FBXgTnmVE24uvG4FyFiXCnRxp2p0FTkx9fpoDZc4N6D27w@mail.gmail.com>

On Sat, Jul 18, 2020 at 06:22:20PM -0700, Wells Oliver wrote:
> Hi: I'm wondering if there's an application of GIN (or otherwise) indexing with
> jsonb columns to help speed up some queries where I'm not using WHERE clauses,
> but unpacking rather large json objects to rows via jsonb_array_elements: it
> seems indexing largely helps when filtering, but this is more unpacking/
> flattening with really quite sizable objects.

You can use JSON (not JSONB) to get faster loading/unloading, but much
slower filtering.

-- 
  Bruce Momjian  <bruce@momjian.us>        https://momjian.us
  EnterpriseDB                             https://enterprisedb.com

  The usefulness of a cup is in its emptiness, Bruce Lee







view thread (2+ messages)

Message-ID: <20200722184225.GD3899@momjian.us>
Permalink:  ../20200722184225.GD3899@momjian.us/
Also on:    postgresql.org/message-id/20200722184225.GD3899@momjian.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: bruce@momjian.us, wells.oliver@gmail.com
  Subject: Re: More efficient access of JSON array elements?
  In-Reply-To: <20200722184225.GD3899@momjian.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox