public inbox for [email protected]  
help / color / mirror / Atom feed
From: Peter Geoghegan <[email protected]>
To: Tom Lane <[email protected]>
Cc: Heikki Linnakangas <[email protected]>
Cc: Greg Stark <[email protected]>
Cc: Bruce Momjian <[email protected]>
Cc: Gavin Flower <[email protected]>
Cc: David E. Wheeler <[email protected]>
Cc: Robert Haas <[email protected]>
Cc: Andrew Dunstan <[email protected]>
Cc: [email protected] <[email protected]>
Subject: Re: default opclass for jsonb (was Re: Call for GIST/GIN/SP-GIST opclass documentation)
Date: Sat, 10 May 2014 18:31:35 -0700
Message-ID: <CAM3SWZQMTFQO3o2Y8i42E-ABOHaJt-0_VtMxzFanp+5nAqD-pQ@mail.gmail.com> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<CAM-w4HOQ+ynm70Cgr4BwMqMc0jfL_8EZAwG2UD6r=EehjH3OOw@mail.gmail.com>
	<[email protected]>
	<[email protected]>
	<CAM3SWZTerM-f8nhmuatR-YhPiMwrqR01=TwtCNM1E9PERkvAAA@mail.gmail.com>
	<CAM3SWZQpg8cX+MccHd38KCQMgD9Leh-4BNBFnV-8gh5+Rnb1Hg@mail.gmail.com>
	<[email protected]>
List-Unsubscribe: <mailto:[email protected]?body=unsub%20pgsql-hackers>

On Sat, May 10, 2014 at 5:54 PM, Tom Lane <[email protected]> wrote:
> I'm not sure whether we have consensus to rename jsonb_hash_ops to
> jsonb_path_ops, but since time is so short I went ahead and made a draft
> patch to do so (attached).  Probably the most interesting part of this is
> the new text in json.sgml explaining the difference between the two
> opclasses.  I also added a paragraph about the empty-query hazard that
> Peter mentions.  Do people think this discussion is correct and useful?

I for one am fine with the name change you propose.

> +     especially if
> +     there are a very large number of rows containing any single one of the
> +     three keys

I suggest that you phrase this as "three index items".

> +     A disadvantage of the <literal>jsonb_path_ops</literal> approach is
> +     that it produces no index entries for JSON structures not containing
> +     any values, such as <literal>{"a": {}}</literal>.  If a search for

I suggest "any values or elements".

Even though I previously called hashing an implementation detail, we
are bound to have to mention it in passing when discussing the
limitations of jsonb_hash_ops/jsonb_path_ops. I think that you should
proceed with committing the entire patch, including the doc changes
that discuss implementation details around the two GIN opclasses.

-- 
Peter Geoghegan


-- 
Sent via pgsql-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers



view thread (65+ messages)  latest in thread

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: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: Re: default opclass for jsonb (was Re: Call for GIST/GIN/SP-GIST opclass documentation)
  In-Reply-To: <CAM3SWZQMTFQO3o2Y8i42E-ABOHaJt-0_VtMxzFanp+5nAqD-pQ@mail.gmail.com>

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

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