On Sat, May 17, 2003 at 04:04:11AM -0700, Don Baccus wrote:
> On Saturday 17 May 2003 10:51 am, Matthew Kirkwood wrote:
> > On Sat, 17 May 2003, Alvaro Herrera wrote:
> > > > > I'm going suggest a feature like what Oracle calls "partitions" and
> > > > > later on something with indexes. The idea is to generate some
> > > > > discussion to see if they are worthy of being added to the TODO list.
> > > >
> > > > Why bother?
> > >
> > > Maybe one can put different partitions in different tablespaces?
> >
> > One can. The tablespace a partition is in can even be
> > offline if Oracle can prove that a query doesn't require
> > that partition.
>
> People use this feature for warehousing old data that they don't want to purge
> from the database. For very large databases (of course that definition
> changes with each new generation of computer) this can greatly improve the
> performance of queries on the active portion of the data.
Or can't delete (eg. financial records). The reason I'm looking at it is for
queries where you want a report depending on all the data for 2002. Since
this data is mixed in with all the data for upto 7 previous years, it's too
big for a index scan but doing a seq. scan across the whole table is
very expensive.
What this buys you is being able to seq. scan over portions of a table,
rather than the whole table. Currently we manage this manually by moving
tuples around after the fact.
Hmm, no comments on the UNIQUE-index-over-multiple-tables. I would have
thought that would've been the more interesting one.
Have a nice weekend.
--
Martijn van Oosterhout <kleptog@svana.org> http://svana.org/kleptog/
> "the West won the world not by the superiority of its ideas or values or
> religion but rather by its superiority in applying organized violence.
> Westerners often forget this fact, non-Westerners never do."
> - Samuel P. Huntington