Oracle Datafiles and Tempfiles - Oracle (MCQ) questions and answers for Q. 3181

Q.  Which SQL Statement creates a new empty datafile in place of an old one-useful to re-create a datafile that was lost with no backup?
- Published on 30 Jul 15

a. ALTER DATABASE...CREATE DATAFILE
b. CREATE DATABASE
c. ALTER TABLESPACE...ADD TEMPFILE
d. CREATE TEMPORARY TABLESPACE

ANSWER: ALTER DATABASE...CREATE DATAFILE
 

    Discussion

  • Nirja Shah   -Posted on 25 Sep 15
    - You can create datafiles and associate them with a tablespace using any of the statements listed in the following table.

    - In all cases, you can either specify the file specifications for the datafiles being created, or you can use the Oracle-managed files feature to create files that are created and managed by the database server.

    - The table includes a brief description of the statement, as used to create datafiles, and references the section of this book where use of the statement is specifically described:

    1. CREATE TEMPORARY TABLESPACE - Creates a locally-managed temporary tablespace and the tempfiles (tempfiles are a special kind of datafile) that comprise it

    2. ALTER TABLESPACE ... ADD TEMPFILE - Creates and adds a tempfile to a temporary tablespace

    3. CREATE DATABASE - Creates a database and associated datafiles

    4. ALTER DATABASE ... CREATE DATAFILE - Creates a new empty datafile in place of an old one--useful to re-create a datafile that was lost with no backup.

Post your comment / Share knowledge


Enter the code shown above:

(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)