From: Richard Huxton <dev@archonet.com>
To: Frank Hagstrom <frank.hagstrom@gmail.com>
Cc: pgsql-sql@postgresql.org
Subject: Re: Possible to use a table to tell what table to select from?
Date: Thu, 14 Jul 2005 09:31:01 +0100
Message-ID: <42D622C5.9000907@archonet.com> (raw)
In-Reply-To: <28b4448e05070813326d98e574@mail.gmail.com>
References: <28b4448e05070813326d98e574@mail.gmail.com>
Frank Hagstrom wrote:
> Hello
>
> I've been thinking on a potential problem I might get in a distant
> future, but once I started thinking on it I just as well had to
> check...
>
> Is it possible to have say ~ 6 tables, where the first one is a
> 'reference' to all the others (they all are with the same structure).
> The other 5 or so have information stored in importance/access/age,
> where one table will be only recent/important things, the other with a
> bit lower priority and so on until the last table that can be really
> huge and slow and used more like a storage ... Is it possible to write
> an SQL query to let the first table figure out what table one will do
> the actual select from?
If the tables are all holding the same sort of thing, e.g. logs2003,
logs2004, logs2005 etc. then you might want to look at partitioning.
This is being looked at for the next version, check the archives of the
hackers list.
--
Richard Huxton
Archonet Ltd
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-sql@postgresql.org
Cc: dev@archonet.com, frank.hagstrom@gmail.com
Subject: Re: Possible to use a table to tell what table to select from?
In-Reply-To: <42D622C5.9000907@archonet.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