Results 1 to 4 of 4

Thread: table space

  1. #1
    Join Date
    Mar 2004
    Posts
    15

    Exclamation Unanswered: table space

    Hi everyone,
    Can somebody give a brief description on creation Table spaces for tables and their advantages in usage of the data.

    Uday

  2. #2
    Join Date
    Jan 2004
    Location
    UK
    Posts
    52
    Tablespaces are logical structures in Oracle. One on many physical data files (OS files) cater space to Tablespaces. Normally, we define different tablespace for storing user data, user indexes etc. ...and that way you can create objects on separate table spaces to have better performance of data management.

  3. #3
    Join Date
    Jan 2004
    Location
    India
    Posts
    113
    With the creation of a DB the system tablespace gets created which is required for DB operation as the data dictionary resides on it.
    It can never be taken as offline.
    We usually create tablespace using the syntax.
    create tablespace <name> datafile <name with path> size ...;

    A tablespace is always associated with a datafile which is a physical (OS) file that actually stores the data.
    A tablespace can contain one or more datafiles . But one datafile cannot be shared b/w two tablespaces.


    After creating the tablespace if u need to store ur table in that particular tablespace then use the following.

    create table t1(col1 varchar2(10)) tablespace_name;
    One more thing we can also attach a particular user with a default tablespace.
    For eg
    Alter user scott default tablespace <tablespace_name>;

    This means if user scott creates any table with specifying any tablespace
    then by default it is going to be stored in the default tablespace of that user.<tablespace_name>

    I hope u can now get along with a good book for some more info.

    Best of luck
    Kaushik

  4. #4
    Join Date
    Mar 2004
    Posts
    15
    Thanks a lot....

    Uday

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •