Re: WORM and Read Only Tables (v0.1) - Mailing list pgsql-hackers

From Zeugswetter Andreas ADI SD
Subject Re: WORM and Read Only Tables (v0.1)
Date
Msg-id E1539E0ED7043848906A8FF995BDA579029CA572@m0143.s-mxs.net
Whole thread Raw
In response to Re: WORM and Read Only Tables (v0.1)  (Andrew Sullivan <ajs@crankycanuck.ca>)
Responses Re: WORM and Read Only Tables (v0.1)  (Andrew Sullivan <ajs@crankycanuck.ca>)
List pgsql-hackers
> There are a number of nasty
> limitations for partitions currently (not the least of which is that
real
> uniqueness guarantees are impractical),

Just to add an other opinion to this statement, because it imho sounds
overly
pessimistic:

Uniqueness is currently perfectly practical, when the unique index
contains
the column[s] that is/are used in a non overlapping partitioning scheme.

If you cannot create separate unique indexes on each partition that
guarantee
global uniqueness because of the chosen partitioning scheme, you can
often
reconsider your scheme (e.g. use natural keys instead of serials).

Other db software allows creating global indexes, or indexes with
separate
partitioning schemes, but this is then often a pain. When you
drop/attach/detach
a partition such an index needs to be recreated or reorganized. This
then makes
a large slow transaction out of attach/detach partition.
If you don't need to attach/detach, there is still one other argument
against
the huge global index which is "fault isolation".

There is imho large room to make it better than others :-)
And I think we should not regard them as positive examples,
because that narrows the view.

Andreas


pgsql-hackers by date:

Previous
From: Oleg Bartunov
Date:
Subject: little correction
Next
From: "Zeugswetter Andreas ADI SD"
Date:
Subject: Re: WORM and Read Only Tables (v0.1)