Ilp Oracle Quiz Prelims 1

16 Questions | Total Attempts: 69

SettingsSettingsSettings
Please wait...
Oracle Quizzes & Trivia

Oracle Quiz Prelims 1


Questions and Answers
  • 1. 
    Which table name is valid?
    • A. 

      Invoices-1996

    • B. 

      Catch_#22

    • C. 

      1996_invoices

    • D. 

      .#_667

  • 2. 
     You attempt to create the salary table with this command:  1. CREATE TABLE salary  2. (employee_id NUMBER(9)  3. CONSTRAINT salary_pk PRIMARY KEY,  4. 1995_salary NUMBER(8,2),  5. manager_nameVARCHAR2(25)  6. CONSTRAINT mgr_name_nn NOT NULL,  7. $salary_96NUMBER(8,2));  Which two lines of this statement will return errors?
    • A. 

      4,5

    • B. 

      1,7

    • C. 

      4,7

    • D. 

      3,7

  • 3. 
    Which datatype should you use for interest rates with varying and unpredictable decimal places,   such as 1.234, 3.4, 5, and 1.23?
    • A. 

      NUMBER(p,s)

    • B. 

      LONG

    • C. 

      NUMBER

    • D. 

      Float

  • 4. 
    Evaluate this SQL script:     CREATE ROLE manager;     " CREATE ROLE clerk;     CREATE ROLE inventory;     CREATE USER scott IDENTIFIED BY tiger;     GRANT inventory TO clerk;     GRANT clerk TO manager;     GRANT inventory TO scott /     How many roles will user SCOTT have access to?
    • A. 

      1

    • B. 

      2

    • C. 

      0

    • D. 

      3

  • 5. 
    In airline reservation system, the entities are date,flight number,place of departure,destination , type of plane and seats available.The primary key is
    • A. 

      Flight number

    • B. 

      Flight number + place of departure

    • C. 

      Flight number + date

    • D. 

      Flight number + destination

  • 6. 
    How many copies of procedure needs to be loaded for execution by multiple users.
    • A. 

      Only one copy

    • B. 

      Equal to number of users

    • C. 

      Equal to number of times the procedure is called

    • D. 

      None of the above

  • 7. 
    Which is not a valid type of trigger
    • A. 

      Database trigger

    • B. 

      Application trigger

    • C. 

      Transaction trigger

    • D. 

      System trigger

  • 8. 
    To find information about trigger status, which of the following views are appropriate?
    • A. 

      USER_TRIGGERS

    • B. 

      USER_OBJECTS

    • C. 

      USER_TRIGGER_COLS

    • D. 

      ALL_TRIGGERS

  • 9. 
     In which of the following trigger, we can use pseudo columns 'old' and 'new'?
    • A. 

      Statement level trigger

    • B. 

      Row level trigger

    • C. 

      Any trigger

    • D. 

      Schema level trigger

  • 10. 
    If we do not mention as row level then the trigger by default is?
    • A. 

      A statement level

    • B. 

      A row level

    • C. 

      A database level

    • D. 

      None of the above

  • 11. 
    When do we get the exception INVALID_CURSOR?
    • A. 

      CURSOR is already open

    • B. 

      CURSOR name is different in DECLARE as with OPEN

    • C. 

      CURSOR name is duplicated

    • D. 

      Referring the already closed CURSOR

  • 12. 
    Which of the following is a valid When clause in a trigger?
    • A. 

      When (:new.job 'President')

    • B. 

      When (.new.job 'President')

    • C. 

      When (new.job 'President')

    • D. 

      None of the above

  • 13. 
    Which view should a user query to display the columns associated with the constraints on a table owned bythe user?
    • A. 

      USER_CONSTRAINTS

    • B. 

      ALL_CONSTRAINTS

    • C. 

      USER_CONS_COLUMNS

    • D. 

      USER_COLUMNS

  • 14. 
    Which statement about implicit cursors is true?
    • A. 

      Programmers need to close all the implicit cursors before the end of the PL/SQL program.

    • B. 

      Programmers can declare implicit cursors by using the CURSOR type in the declaration section.

    • C. 

      Implicit cursors are declared implicitly only for DML statements.

    • D. 

      Implicit cursors are declared implicitly for all the DML and SELECT statements.

  • 15. 
    Which of the following is false?
    • A. 

      Generally we use commit/rollback inside the cursor for loop

    • B. 

      Generally we use commit/rollback outside the cursor for loop

    • C. 

      Generally we do not use commit/rollback with the cursor for loop

    • D. 

      None of the above

  • 16. 
    Which of the following clauses is valid with cursor for update?
    • A. 

      Where current of

    • B. 

      Where cursor of

    • C. 

      Where update of

    • D. 

      None of the above