Call now: 252-767-6166  
Oracle Training Oracle Support Development Oracle Apps

Free Oracle Tips

HTML Text

 Home
 E-mail Us
 Oracle Articles


 Oracle Training
 Oracle Tips

 Oracle Forum
 Class Catalog


 Remote DBA
 Oracle Tuning
 Emergency 911
 RAC Support
 Apps Support
 Analysis
 Design
 Implementation
 Oracle Support


 SQL Tuning
 Security

 Oracle UNIX
 Oracle Linux
 Monitoring
 Remote s
upport
 Remote plans
 Remote
services
 Application Server

 Applications
 Oracle Forms
 Oracle Portal
 App Upgrades
 SQL Server
 Oracle Concepts
 Software Support

 Remote S
upport  
 Development  

 Implementation


 Consulting Staff
 Consulting Prices
 Help Wanted!

 


 Oracle Posters
 Oracle Books

 Oracle Scripts
 Ion
 Excel-DB   


 

 

 


 

 

 
 

Oracle temporary tablespace groups

Oracle Tips by Burleson Consulting

By Mike Ault

Oracle 10g introduces a new term called “temporary tablespace group.”

Temporary Tablespace Group Overview

A temporary tablespace group consists of only temporary tablespace, and has the following properties:

      • It contains one or more temporary tablespaces.
      • It contains only temporary tablespace.
      • It is not explicitly created. It is created implicitly when the first temporary tablespace is assigned to it, and is deleted when the last temporary tablespace is removed from the group.

Temporary Tablespace Group Benefits

Temporary tablespace group has the following benefits:

      • It allows multiple default temporary tablespaces to be specified at the database level.
      • It allows the user to use multiple temporary tablespaces in different sessions at the same time.
      • It allows a single SQL operation to use multiple temporary tablespaces for sorting.

New Data Dictionary View

Oracle 10g introduces a new data dictionary view, dba_tablespace_groups, for the temporary tablespace group. Using a tablespace with a temporary tablespace group will result in the following select statement. However, using a tablespace without a temporary tablespace group will not return the select statement below.

select    
   tablespace_name, group_name
from    
   DBA_TABLESPACE_GROUPS;
TABLESPACE_NAME	GROUP_NAME
---------------	-----------
TEMP01		TEMPGROUP_A
TEMP02		TEMPGROUP_A
TEMP03		TEMPGROUP_B

Examples

Example 1: Create a temporary tablespace and implicitly add it to a temporary tablespace group.

     CREATE TEMPORARY TABLESPACE temp01
     TEMPFILE ‘/u02/oradata/temp01.dbs’ SIZE 500M
     TABLESPACE GROUP tempgroup_a;

Example 2: Create a temporary tablespace without assigning it to a temporary tablespace group.

The following two statements are exactly equivalent:

     CREATE TEMPORARY TABLESPACE temp04
     TEMPFILE ‘/u02/oradata/temp04.dbs’ SIZE 200M
     TABLESPACE GROUP ‘’;

     CREATE TEMPORARY TABLESPACE temp04
     TEMPFILE ‘/u02/oradata/temp04.dbs’ SIZE 200M;

Example 3: Remove a temporary tablespace from a temporary tablespace group.

This statement will remove temporary tablespace temp04 from its original temporary tablespace group:

     ALTER TABLESPACE temp04 TABLESPACE GROUP ‘‘;

Example 4: Add a temporary tablespace to a temporary tablespace group.

     ALTER TABLESPACE temp03 TABLESPACE GROUP tempgroup_b;

Example 5: Assign a user to a default temporary tablespace group.

In this case, user Scott will have multiple default temporary tablespaces (see Figure 3.1). A single SQL operation by Scott can use more than one temporary tablespace for sorting.

     ALTER USER scott TEMPORARY TABLESPACE tempgroup_A;

Figure 3.1: Temporary tablespace

 

 

If you like Oracle tuning, you may enjoy my new book "Oracle Tuning: The Definitive Reference", over 900 pages of BC's favorite tuning tips & scripts. 

You can buy it direct from the publisher for 30%-off and get instant access to the code depot of Oracle tuning scripts.


 

 

  
 

 
 
 
 
Oracle performance tuning software
 
 

 

 
 
 
Oracle performance Tuning 10g reference poster
 
 
 
Oracle training in Linux commands
 
Oracle training Excel
 
Oracle training & performance tuning books
 

 

Burleson is the American Team

Note: This Oracle documentation was created as a support and Oracle training reference for use by our DBA performance tuning consulting professionals.  Feel free to ask questions on our Oracle forum.

Verify experience! Anyone considering using the services of an Oracle support expert should independently investigate their credentials and experience, and not rely on advertisements and self-proclaimed expertise. All legitimate Oracle experts publish their Oracle qualifications.

Errata?  Oracle technology is changing and we strive to update our BC Oracle support information.  If you find an error or have a suggestion for improving our content, we would appreciate your feedback.  Just  e-mail:  and include the URL for the page.


                    









Burleson Consulting

The Oracle of Database Support

Oracle Performance Tuning

Remote DBA Services


 

Copyright © 1996 -  2012 

All rights reserved.

Oracle © is the registered trademark of Oracle Corporation.