DB2 Online Quiz



Following quiz provides Multiple Choice Questions (MCQs) related to DB2. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.

Questions and Answers

Q 1 - Collection of one or more DASD volumes creates a storage group. What is the maximum limit of DASD which can be used for a storage group?

A - 125

B - 200

C - 133

D - 123

Answer : C

Explanation

This is self explanatory.

Answer : D

Explanation

The purpose of index is to retrieve the data faster. So we choose those columns which are unique or less frequently updated.

Q 3 - How many primary keys can be declared on a table?

A - No Limit

B - Only 1

C - 5

D - 10

Answer : B

Explanation

A table can have only one primary key.

Answer : B

Explanation

DCLGEN stands for Declaration Generator.

Answer : D

Explanation

SQLCODE -818 is a timestamp mismatch of load module and bind timestamp built from DBRM.

Q 6 - How you will count the number of rows from a table TAB?

A - SELECT COUNT FROM TAB

B - SELECT MAX(*) FROM TAB

C - SELECT COUNT(*) FROM TAB

D - None of these

Answer : C

Explanation

This is self explanatory.

Q 7 - What action DB2 takes when a program abends?

A - Auto Rollback

B - Auto Commit

C - Acquire

D - Release

Answer : A

Explanation

When a program abends in middle of some transaction then DB2 performs a auto rollback.

Q 8 - Static SQL is compiled and optimized prior to its execution where as dynamic SQL is compiled and optimized during execution. State whether true or false?

A - False

B - True

Answer : B

Explanation

This is self explanatory.

Q 9 - Fetch statement identifies the cursor and puts the value in INTO clause. A Fetch statement is coded in loop as we get one row at a time. State whether true or false?

A - False

B - True

Answer : B

Explanation

This is self explanatory.

Q 10 - What is the physical storage length of DATE data type?

A - 4 bytes

B - 3 bytes

C - 10 bytes

D - 20 bytes

Answer : A

Explanation

DATE data types take 4 bytes and default is 'YYYY-MM-DD'

db2_questions_answers.htm
Advertisements