Re: Temp tables on Oracle

From: Ricardo Venturini <Ricardo>
Date: 1995/11/03
Message-ID: <47crlf$134u_at_esrinr.cs.esrin.esa.it>#1/1


Bob Beauchemin <bobb_at_udp.com> wrote:
> Another beginner question...
>
> Is there a concept of temporary tables, unique by
>user/process id on Oracle? Is so, how does one specify them?
> I'm looking to use a temporary table to store the results
>of a query for further processing. I was told I could define
>a "permenent" table and insert/delete records that were
>uniquified by a sequence. But this would cause I huge amount
>of activity and fragmentation on the single table.
> A better solution would be the equivalent of the #temp
>table type. Does Oracle support this?

Bob

You could execute the following commands in SQL*Plus:

Create table TEMP1 as select <your 1st query>..... select ......from TEMP1 <your 2nd query>....... etc etc
drop table TEMP1

The TEMP1 table would be unique to a user. You should create a tablespace for the users and make this as a default tablespace, so all the rubbish can to this default tablespace.

Ricardo

      _/_/_/_/_/            _/_/_/_/_/            _/_/_/_/_/
    _/_/_/_/_/_/_/        _/_/_/_/_/_/_/        _/_/_/_/_/_/_/
   _/_/        _/_/      _/_/        _/_/                  _/_/
  _/_/          _/_/  Ricardo Venturini - Software Eng      _/_/
 _/_/_/_/_/_/_/_/_/_/ mailto:rventuri_at_mail.esrin.esa.it _/_/_/_/  _/_/_/_/_/_/_/_/_/_/ ESA http://www.esrin.esa.it/ _/_/_/_/_/_/_/
  _/_/                ESRIN http://www.cs.esrin.esa.it/     _/_/
   _/_/                  _/_/        _/_/      _/_/        _/_/
    _/_/_/_/_/_/_/        _/_/_/_/_/_/_/        _/_/_/_/_/_/_/
      _/_/_/_/_/            _/_/_/_/_/            _/_/_/_/_/
Received on Fri Nov 03 1995 - 00:00:00 CET

Original text of this message