Вы находитесь на странице: 1из 5

Oracle Questions

Max Marks 100 Time:2Hrs

Questions 1-15 State whether the following statements are true or false

1) COMMIT indicates the end of a transaction


(a) True (b) False

2) A Null Value is nothing but equivalent to a Zero value


(a) True (b) False

3) A DBMS can be considered as Relational only if it satisfies CODD’s 12 rules


(a) True (b) False

4) Referential Integrity can be applied to a single Table


(a) True (b) False

5) The integrity rules maintain the consistency of a database


(a) True (b) False

6) A Table can only have one FOREIGN KEY


(a) True (b) False

7) Two Views cannot be created on a single Table


(a) True (b) False

8) PRIMARY KEY Constraint is a must for all Tables


(a) True (b) False

9) A Synonym is an alias name for a base table


(a) True (b) False

10) Normalization helps reducing redundancy in a database


(a) True (b) False

11) A JOIN fetches data from two or more tables that are related by some condition
(a) True (b) False

12) Data redundancy is the state whereby some data within a database is unnecessarily
duplicated
(a) True (b) False

13) Oracle is based on the Hierarchical database model


(a) True (b) False
14) The Increment value in FOR Loop can be changed to 5
(a) True (b) False

15) A function can return more than one value.


a) True B) False

Questions 16-50 : Select the most appropriate answer from the choices given below
mark each)

16) A Table can have maximum ___________ Columns


(a) 255 (b) 1025
(c) 1000 (d) 1024

17) Oracle follows the below given Database Model


(a) Hierarchical Database Model (b) Network Database Model
(c) Relational Database Model (d) None of the above

18) The are ______________ types of Cursors


(a) 4 (b) 5
(c) 1 (d) 2

19)The following Relational concept introduces redundancy (intentional) into a table


(a) Normalization (b) Denormalization
(c) Union (d) Intersection

20) The following Relational concept ensures the corrective ness and completeness of the
data in a database.
(a) Normalization (b) Denormalization
(c) Data Integrity (d) Data Validity

21) A _________ acts as a window to a base table.


(a) Synonym (b) duplicate table
(c) View (d) Cluster

22) MERGE is a new ________________


(a) DDL (b) DML
(c) DCL (d) XML

23) The GRANT Command is an example for


(a) DDL (Data Definition Language) (b) DML (Data Manipulation Language)
(c) DCL (Data Control Language) (d) None of the above

24) In PL/SQL error conditions are called __________________


(a) Errors (b) Exceptions
(c) Run Time Errors (d) PL/SQL Errors

25 ) To avoid duplicate rows in a table we use the following constraint.


(a) Primary Key (b) Foreign Key
(c) Alternate Key (d) Candidate Key

26) Parameters of a Procedure can of the following Type


(a) IN (b) IN/OUT
(c) OUT (d) All of the Above

27) A Package can have only the following


(a) Functions (b) Functions, Procedures, Variables, Cursors, Records
(c) Functions & Procedures (d) None of the above

28) Uniqueness can also be enforced (apart from Primary Key) by creating a
___________
(a) Foreign Key (b) Unique Index
(c) Index (d) View

29) Currval and Nextval are ___________ columns.


(a) Unique (b) Aggregate Function
(c) Pseudo (d) None of the above

30) If a SELECT statement with in a PL/SQL runs does not retrieve any rows then the
following pre-defined exception is raised.
(a) no_data_found (b) lot_of_rows
(c) many_rows (d) too_many_rows

31) A function has two parts, namely specification and the ___________
(a) function body (b) function code
(c) function definition (d) function declaration

32) Restrictions on a trigger can be achieved using the following clause


(a) RESTRICT (b) WHEN
(c) WHILE (d) FOR

33) All the triggers defined for a specific table can be enabled by using the following
clause
(a) ENABLE ALL (b) ENABLE
(c) ENABLE ALL TRIGGERS (d) None of the above0

34) After issuing a DML statement (Update, Delete,..), changes to the records can be
cancelled by using the following command
(a) COMMIT (b) ROLLBACK
(c) UNDO (d) CANCEL

35) The CASE expression can be used in


(a) SQL (b) SQL and PL/SQL
(c) PL/SQL (d) Not Available in Oracle9i

36) The _______ statement of a Cursor retrieves the current row and advances the cursor
to the next row.
(a) Open (b) Fetch
(c) Retrieve (d) None of the above

37) The _______ Cursor attribute can be used to check whether a Cursor is open or not
(a) %whenopen (b) %isopen
(c) %open (d) %whileopen

38) After issuing a DML statement ( Udpate, Delete,..), changes to the records can be
cancelled by using the following command
(a) COMMIT (b) ROLLBACK
(c) UNDO (d) CANCEL

39) The following function is an example for GROUP function


(a) MAX (b) ADD_MONTHS
(c) UPPER (d) MONTHS_BETWEEN

40) The _______ statement of a Cursor retrieves the current row and advances the cursor
to the next row.
(a) Open (b) Fetch
(c) Retrieve (d) None of the above

41) There are ______________ types of Loop Control Structures in PL/SQL


(a) 2 (b) 4
(c) 1 (d) 3

42) When multiple table columns are included in the index, it is called a _______
a) Composite Index b) Primary index
c) Clustered index d) Primary Key
43) The BIND variable declared in a Session can be used in
a) SQL only b) PL/SQL only
c) Both SQL and PL/SQL d) None of the Above

44) Comments in PL/SQL can be specified by using __________ and __________


a) // b) \\
c) /* */ d) - -

45) _____________ is used to display message to the user.


a) DBMS_OUTPUT.PUT_LINE b) SYSTEM_OUTPUT.PUT_LINE
c) PUT_LINE d) DBMS_OUTPUT

46) _______________is used for Error trapping in PL/SQL block


a) {} b) try {} catch{}
c) Exception section d) none of the above

47) ________________ Are PL/SQL blocks that return values and are stored in the
database.
a) Procedure b) Trigger
c) Cursor d) Function

48) _________________ are PL/SQL blocks that fire when an Insert,


Update or Delete is performed on the table.
a) Cursor b) Iterator
c) Database triggers d) Constraints

49) __________________ is a collection of Stored Procedure and Functions.


a) Group b) Interface
c) Package d) Folder

50) _______________ section is Not Optional in PL/SQL


a) Declarative Section b) Executable section
b) Exception Section d) All of the Above

Вам также может понравиться