Re: Temporary tables and indexes

From: "Ian Harding" <ianh(at)tpchd(dot)org>
To: <pgsql-sql(at)postgresql(dot)org>
Subject: Re: Temporary tables and indexes
Date: 2002-10-08 16:13:23
Message-ID: sda2a224.029@mail.tpchd.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Sure there is! There are queries that benefit from having a temporary table created for a subquery and the temporary table indexed before the join. Since we can't easily return result sets from functions yet, it's not probably used that much, but from within a function, I can see why you might want to do this from time to time.

Ian A. Harding
Programmer/Analyst II
Tacoma-Pierce County Health Department
(253) 798-3549
iharding(at)tpchd(dot)org

WWSD - What Would Scooby Doo?

>>> "Josh Berkus" <josh(at)agliodbs(dot)com> 10/08/02 08:36AM >>>
Ludwig,

> Are the indices of a temporary table automatically
> "dropped" together its corresponding temporary table
> after a database session?

I'm kind of surprised that it's possible to index a temporary table.
There's not much point in doing so.

Yes, the indexes would be dropped as well.

-Josh Berkus

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

Browse pgsql-sql by date

  From Date Subject
Next Message Richard Huxton 2002-10-08 16:44:15 Re: Problems Formulating a SELECT
Previous Message Tom Lane 2002-10-08 15:51:12 Re: [GENERAL] Large databases, performance