pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Noah Misch <noah@leadboat.com>
To: Marco Nenciarini <marco.nenciarini@2ndQuadrant.it>
Cc: pgsql-hackers@postgresql.org
Subject: Re: [PATCH] Support for foreign keys with arrays
Date: Tue, 20 Mar 2012 01:07:52 -0400
Message-ID: <20120320050752.GA11554@tornado.leadboat.com> (raw)
In-Reply-To: <1332178899.2278.4.camel@greygoo.devise-it.lan>
References: <4EE31CB9.90005@2ndQuadrant.it>
	<20111212004506.GB10399@tornado.leadboat.com>
	<1326568728.2613.16.camel@greygoo.devise-it.lan>
	<20120121204223.GA2388@tornado.leadboat.com>
	<4F280EFE.1080604@2ndQuadrant.it>
	<1328551482.3354.64.camel@greygoo.devise-it.lan>
	<20120225020135.GA27204@tornado.leadboat.com>
	<1331748188.6744.15.camel@greygoo.devise-it.lan>
	<20120317033312.GB19556@tornado.leadboat.com>
	<1332178899.2278.4.camel@greygoo.devise-it.lan>

On Mon, Mar 19, 2012 at 06:41:39PM +0100, Marco Nenciarini wrote:
> Attached is v5, which should address all the remaining issues.

Looks clean to me.

> On Fri, Mar 16, 2012 at 11:33:12PM -0400, Noah Misch wrote:
> > If the cost doesn't exceed O(F log P), where F is the size of the FK table and
> > P is the size of the PK table, I'm not worried.  If it can be O(F^2), we would
> > have a problem to be documented, if not fixed.
> 
> We have rewritten the old query in a simpler way; now its cost is O(F log P).
> Here F must represent the size of the "flattened" table, that is, the total
> number of values that must be checked, which seems a reasonable assumption
> in any case.

Great; I find that approach easier to reason about.



view thread (62+ messages)  latest in thread

Message-ID: <20120320050752.GA11554@tornado.leadboat.com>
Permalink:  ../20120320050752.GA11554@tornado.leadboat.com/
Also on:    postgresql.org/message-id/20120320050752.GA11554@tornado.leadboat.com

 · 

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-hackers@postgresql.org
  Cc: noah@leadboat.com, marco.nenciarini@2ndQuadrant.it
  Subject: Re: [PATCH] Support for foreign keys with arrays
  In-Reply-To: <20120320050752.GA11554@tornado.leadboat.com>

* 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