Basics Of Data Types And Database Objects

Approved & Edited by ProProfs Editorial Team
The editorial team at ProProfs Quizzes consists of a select group of subject experts, trivia writers, and quiz masters who have authored over 10,000 quizzes taken by more than 100 million users. This team includes our in-house seasoned quiz moderators and subject matter experts. Our editorial experts, spread across the world, are rigorously trained using our comprehensive guidelines to ensure that you receive the highest quality quizzes.
Learn about Our Editorial Process
| By Kalloorkar_bvk
K
Kalloorkar_bvk
Community Contributor
Quizzes Created: 2 | Total Attempts: 955
Questions: 5 | Attempts: 339

SettingsSettingsSettings
Data Type Quizzes & Trivia

The quiz checks if trainee has understood basic concepts of table creation and database objects


Questions and Answers
  • 1. 

    Which of these statements will fail because the table name is not legal? (Choose two answers.)

    • A.

      Create table "SELECT" (col1 date);

    • B.

      Create table "lower case" (col1 date);

    • C.

      Create table number1 (col1 date);

    • D.

      Create table update(col1 date);

    • E.

      Create table 1number(col1 date);

    Correct Answer(s)
    D. Create table update(col1 date);
    E. Create table 1number(col1 date);
    Explanation
    The table name "update" will fail because it is a reserved SQL keyword and cannot be used as a table name. The table name "1number" will also fail because it starts with a number, which is not allowed in SQL table names.

    Rate this question:

  • 2. 

    Several object types share the same namespace and therefore cannot have the same name in the same schema. Which of the following object types is not in the same namespace as the others? (Choose the best answer.)

    • A.

      Index

    • B.

      PL/SQL stored procedure

    • C.

      Synonym

    • D.

      Table

    • E.

      View

    Correct Answer
    A. Index
    Explanation
    Indexes, PL/SQL stored procedures, synonyms, tables, and views are all object types that exist within a schema. However, indexes are not in the same namespace as the others. Indexes are used to improve the performance of database queries by allowing for faster data retrieval. They are not directly related to the structure or definition of the data itself, unlike tables, views, and synonyms. Therefore, indexes have a separate namespace from the other object types mentioned.

    Rate this question:

  • 3. 

    Which of the following is not supported by Oracle as an internal datatype? (Choose the best answer.)

    • A.

      CHAR

    • B.

      FLOAT

    • C.

      INTEGER

    • D.

      STRING

    Correct Answer
    D. STRING
    Explanation
    Oracle does not support the internal datatype "STRING." The other options, CHAR, FLOAT, and INTEGER, are all supported by Oracle as internal datatypes.

    Rate this question:

  • 4. 

    You need to record date/time values, with a precision of one second. What would be a suitable datatype for a single column to store this information? (Choose One that is most appropriate)

    • A.

      DATE

    • B.

      TIMESTAMP

    • C.

      DATE or TIMESTAMP

    • D.

      User Defined Data Type

    Correct Answer
    C. DATE or TIMESTAMP
    Explanation
    A suitable datatype for recording date/time values with a precision of one second would be TIMESTAMP. The TIMESTAMP datatype allows for storing both date and time information, including seconds. DATE datatype only stores the date information without the time component. Therefore, TIMESTAMP is the most appropriate choice for this requirement.

    Rate this question:

  • 5. 

    Which of the following constraints require an index? (Choose Two)

    • A.

      NOT NULL

    • B.

      PRIMARY KEY

    • C.

      CHECK

    • D.

      UNIQUE

    Correct Answer(s)
    B. PRIMARY KEY
    D. UNIQUE
    Explanation
    The PRIMARY KEY constraint requires an index because it ensures that each value in the specified column(s) is unique and also serves as a unique identifier for each row in the table. An index is needed to efficiently enforce this constraint and allow for fast lookup and retrieval of data based on the primary key. Similarly, the UNIQUE constraint also requires an index to enforce the uniqueness of values in the specified column(s), allowing for efficient data retrieval and preventing duplicate entries.

    Rate this question:

Quiz Review Timeline +

Our quizzes are rigorously reviewed, monitored and continuously updated by our expert board to maintain accuracy, relevance, and timeliness.

  • Current Version
  • Mar 21, 2023
    Quiz Edited by
    ProProfs Editorial Team
  • Jan 26, 2012
    Quiz Created by
    Kalloorkar_bvk
Back to Top Back to top
Advertisement
×

Wait!
Here's an interesting quiz for you.

We have other quizzes matching your interest.