Re: Postgres-R: primary key patches - Mailing list pgsql-hackers

From chris
Subject Re: Postgres-R: primary key patches
Date
Msg-id 87sku8wo5f.fsf@dba2.int.libertyrms.com
Whole thread Raw
In response to Postgres-R: primary key patches  (Markus Wanner <markus@bluegap.ch>)
Responses Re: Postgres-R: primary key patches
List pgsql-hackers
markus@bluegap.ch (Markus Wanner) writes:
> as you might know, Postgres-R relies on primary keys to address tuples
> of a table. It cannot replicate tables without a primary key.

Slony-I does the same, with the "variation" that it permits the option
of using a "candidate primary key," namely an index that is unique+NOT
NULL.

If it is possible to support that broader notion, that might make
addition of these sorts of logic more widely useful.

> Primary keys currently aren't really used within the executor, so I
> had to extended and modify Postgres here and there, to get the
> required information. To ease reviewing I have split out these
> modifications and present them here as two separate little patches.

I know Jan Wieck has in mind the idea of adding an interface to enable
doing highly efficient IUD (Insert/Update/Delete) via generating a way
to do direct heap updates, which would be *enormously* more efficient
than the present need (in Slony-I, for instance) to parse, plan and
execute thousands of IUD statements.  For UPDATE/DELETE to work
requires utilizing (candidate) primary keys, so there is some
seemingly relevant similarity there.
-- 
select 'cbbrowne' || '@' || 'linuxfinances.info';
http://cbbrowne.com/info/lsf.html
Rules  of the  Evil Overlord  #145. "My  dungeon cell  decor  will not
feature exposed pipes.  While they add to the  gloomy atmosphere, they
are good  conductors of vibrations and  a lot of  prisoners know Morse
code." <http://www.eviloverlord.com/>


pgsql-hackers by date:

Previous
From: Simon Riggs
Date:
Subject: Re: [PATCH]-hash index improving
Next
From: Markus Wanner
Date:
Subject: Re: Postgres-R: primary key patches