Re: JSONB Array of Strings (with GIN index) versus Split Rows (B-Tree Index)

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: Syed Jafri <syed(dot)jafri2(at)ucalgary(dot)ca>
Cc: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: JSONB Array of Strings (with GIN index) versus Split Rows (B-Tree Index)
Date: 2019-02-04 22:02:44
Message-ID: CAKFQuwb7RkZVjyCQ=4vJiS_LKmj2pVUB47N991vSPoQohVx9Xg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Sun, Feb 3, 2019 at 10:35 PM Syed Jafri <syed(dot)jafri2(at)ucalgary(dot)ca> wrote:
> · Receiver names are of the type (a-z, 1-5, .)
>
> · 95% of all queries currently look like this: SELECT * FROM table WHERE Receiver = Alpha, with the new format this would be SELECT * FROM table WHERE receivers @> '"Alpha"'::jsonb;
> 3. Which option is more efficient? Which is faster?

I'd probably develop a performance test for the model and planned
queries and experiment with:

1. text arrays
2. jsonb arrays
3. partitioning

David J.

In response to

Browse pgsql-general by date

  From Date Subject
Next Message rob stone 2019-02-04 22:05:41 Re: Server goes to Recovery Mode when run a SQL
Previous Message Ian Zimmerman 2019-02-04 21:44:25 Re: JSONB Array of Strings (with GIN index) versus Split Rows (B-Tree Index)