Home »
MCQs
DB2 Multiple-Choice Questions (MCQs)
DB2 is a family of data management products, including database servers, developed by IBM. It initially supported the relational model, but was extended to support object–relational features and non-relational structures like JSON and XML. Read more at Wikipedia
DB2 MCQs: This section contains multiple-choice questions and answers on the various topics of DB2. Practice these MCQs to test and enhance your skills on DB2.
List of DB2 MCQs
1. DB2 is a ____?
- NoSQL
- RDBMS
Answer: B) RDBMS
Explanation:
DB2 is a relational database management system.
Discuss this Question
2. Does DB2 support object-oriented features?
- Yes
- No
Answer: A) Yes
Explanation:
Yes, DB2 supports object-oriented features.
Discuss this Question
3. Which company developed DB2?
- Google
- Facebook
- IBM
- Apache
Answer: C) IBM
Explanation:
DB2 was developed by IBM.
Discuss this Question
4. DB2 can run on which of the following operating system?
- Linux
- Unix
- Windows
- All of the above
Answer: D) All of the above
Explanation:
DB2 can run on any operating system such as Linux, Unix, or windows.
Discuss this Question
5. An ____- is DB2 Database Manager's logical environment?
- Environment
- Directory
- Instance
- Object
Answer: C) Instance
Explanation:
An instance is DB2 Database Manager's logical environment.
Discuss this Question
6. The default instance for DB2 Database Server is ____?
- Database
- DB2
- databaseinstance
Answer: B) DB2
Explanation:
The default instance for DB2 Database Server is "DB2".
Discuss this Question
7. Can you modify the location of the Instance directory once it has been created?
- Yes
- No
Answer: B) No
Explanation:
It is not possible to modify the location of the Instance directory once it has been created.
Discuss this Question
8. Several databases can be managed by a single instance.
- True
- False
Answer: A) True
Explanation:
Several databases can be managed by a single instance.
Discuss this Question
9. In an instance, two or more databases can have the same name?
- Yes
- No
Answer: B) No
Explanation:
In an instance, each database has a unique name, its own set of catalog tables, configuration files, authorities, and privileges.
Discuss this Question
10. Is it possible to install multiple DB2Servers on a physical machine?
- Yes
- No
Answer: A) Yes
Explanation:
Several DB2Servers can be installed on a single physical computer.
Discuss this Question
11. Which command displays a list of all the instances available on a system?
- db2list
- db2listi
- listDB2
- db2ilist
Answer: D) db2ilist
Explanation:
db2ilist command displays a list of all the instances available on a system.
Discuss this Question
12. Which command displays information about the presently running instance?
- db2 get all instance
- db2 get present instance
- db2 get instance
Answer: C) db2 get instance
Explanation:
db2 get instance command displays information about the presently running instance.
Discuss this Question
13. Which of the following command starts an instance?
- DB2run
- DB2start
- DB2initiate
Answer: B) DB2start
Explanation:
DB2Start command starts an instance.
Discuss this Question
14. Which of the following command is used to stop a running instance?
- DB2pause
- DB2Stop
- DB2end
- DB2exit
Answer: B) DB2Stop
Explanation:
DB2stop command is used to stop a running instance.
Discuss this Question
15. Is instance id a root id.
- Yes
- No
Answer: B) No
Explanation:
Instance id is not a root id or a root name.
Discuss this Question
16. To update the instance, ____ command is used.
- Db2iupdt
- Db2update
- Db2updt
Answer: A) Db2iupdt
Explanation:
To update the instance, db2iupdt command is used.
Discuss this Question
17. Which command is used to drop an instance?
- DB2IDEL
- Db2idelete
- Db2idrop
Answer: C) Db2idrop
Explanation:
db2idrop command is used to drop an instance.
Discuss this Question
18. A ____ is a well-organized collection of databases.
- Database instance
- Database directory
- Database guide
- Database Catalog
Answer: B) Database directory
Explanation:
A database directory is a well-organized collection of databases.
Discuss this Question
19. Partition global directory is created in the ____ folder.
- Instance
- Object
- Data
- Database
Answer: A) Instance
Explanation:
The partition global directory is created in the instance folder.
Discuss this Question
20. Where a member-specific directory is created?
- Instance folder
- Global directory
- partition-global
Answer: C) partition-global
Explanation:
A member-specific directory is generated in the partition-global directory.
Discuss this Question
21. With the "____" command, you may create a database.
- CREATE DB
- CREATE NEW DB
- NEW DATABASE
- CREATE DATABASE
Answer: D) CREATE DATABASE
Explanation:
With the "CREATE DATABASE" command, you may create a database.
Discuss this Question
22. All database tables are kept in "____" in DB2?
- Database
- Directory
- Table
- Tablespace
Answer: D) Tablespace
Explanation:
All database tables are kept in "tablespace" in DB2.
Discuss this Question
23. Which command is used to view the directory list in the current instance?
- db2 list database directory
- db2 list directory
- db2 directory list
- db2 directory database list
Answer: A) db2 list database directory
Explanation:
db2 list database directory and the command is used to view the directory list in the current instance.
Discuss this Question
24. To utilize a database once it has been created, ____ command is used to connect or start the database.
- db2 connect <database name>
- db2 connection to <database name>
- db2 start to <database name>
Answer: A) db2 connect <database name>
Explanation:
To utilize a database once it has been created, db2 connect to <database name>, the command is used to connect or start the database.
Discuss this Question
25. The ____ is a section of main memory allocated by the database management.
- Cache
- Bufferpool
- Dram
- Tablespaces
Answer: B) Bufferpool
Explanation:
The bufferpool is a section of the main memory allocated by the database management.
Discuss this Question
26. Every database has its own bufferpool.
- True
- False
Answer: A) True
Explanation:
Every database has its own bufferpool.
Discuss this Question
27. The purpose of ____ is to cache table and index data from disk.
- BufferPools
- StoragePools
- CacheData
- Tablespaces
Answer: A) BufferPools
Explanation:
The purpose of bufferpools is to cache tables and index data from disk.
Discuss this Question
28. ____ bufferpool is coupled with ____ tablespace?
- One, many
- Many, one
- One, one
- Many, many
Answer: C) One, one
Explanation:
One bufferpool is coupled with one tablespace.
Discuss this Question
29. Once the bufferpool is created, Is it possible to modify the page size later?
- Yes
- No
Answer: B) No
Explanation:
Once the bufferpool is created, it is not possible to modify the page size later.
Discuss this Question
30. What is the default bufferpool page size?
- 10KB
- 100KB
- 5KB
- 4KB
Answer: D) 4KB
Explanation:
The default bufferpool page size is 4KB.
Discuss this Question
31. The size of bufferpool and tablespace must be the same.
- True
- False
Answer: A) True
Explanation:
The size of bufferpool and tablespace must be the same.
Discuss this Question
32. To build a new bufferpool for the database server, how many parameters are required?
- 3
- 4
- 2
- 5
Answer: C) 2
Explanation:
To build a new bufferpool for the database server, you will need two parameters: "bufferpool name" and "page size".
Discuss this Question
33. Is it necessary to check if the bufferpool is assigned to a tablespace before dropping it?
- Yes
- No
Answer: A) Yes
Explanation:
Yes, Before removing the bufferpool, it must be checked to see if it has any tablespaces assigned to it.
Discuss this Question
34. A ____ is a type of storage structure that contains tables, indexes, huge objects, and lengthy data.
- Table store
- table space
- Clear table
- Data fields
Answer: B) table space
Explanation:
A table space is a type of storage structure that contains tables, indexes, huge objects, and lengthy data.
Discuss this Question
35. Tablespaces includes only one container?
- Yes
- No
Answer: B) No
Explanation:
Tablespaces includes one or more containers.
Discuss this Question
36. A container can be ____.
- a device name
- a directory name
- a filename
- All of the above
Answer: D) All of the above
Explanation:
A container can be a device name, a directory name, or a filename.
Discuss this Question
37. A single tablespace in a database can have ____ containers on the same physical storage device.
- Only one
- Many
- More than 2 but less than 5
Answer: B) Many
Explanation:
A single tablespace in a database can have several containers on the same physical storage device.
Discuss this Question
38. What is SMS?
- Simple management service
- System-managed space
- System management service
Answer: B) System-managed space
Explanation:
SMS stands for system manages space.
Discuss this Question
39. What is DMS?
- Data management service
- Data management space
- Database managed space
- Database managed service
Answer: C) Database managed space
Explanation:
DMS stands for database manages space.
Discuss this Question
40. A set of Storage routes to store database tables or objects, called a ____.
- Storage group
- Memory group
- Retention group
Answer: A) Storage group
Explanation:
A set of Storage routes to store database tables or objects, called a storage group.
Discuss this Question
41. A ____ is a set of named items that are logically categorized in a database.
- Table
- Fields
- Schema
- Views
Answer: C) Schema
Explanation:
A schema is a set of named items that are logically categorized in a database.
Discuss this Question
42. Which of the following command will give you the currently active schema?
- db2 get schema
- db2 list schema
- db2 active schema
Answer: A) db2 get schema
Explanation:
db2 get schema, the command will give you the currently active schema.
Discuss this Question
43. A ____ is a collection of data kept in the form of columns and rows.
- Views
- Tables
- Schema
- Fields
- Datatype
Answer: B) Tables
Explanation:
A table is a collection of data kept in the form of columns and rows.
Discuss this Question
44. Which of the following commands lists the columns in a table?
- db2 desc table <table_name>
- db2 col table <table_name>
- db2 describe table <table_name>
- db2 descri table <table_name>
Answer: C) db2 describe table <table_name>
Explanation:
db2 describes table <table_name>, commands lists the columns in a table.
Discuss this Question
45. An ____ is a different name for a database entity?
- Rename
- Revoke
- Alias
- Pseudonym
Answer: C) Alias
Explanation:
An alias is a different name for a database entity.
Discuss this Question
46. To ensure database integrity, a set of rules known as ____ is specified?
- Limitations
- Constraints
- Limits
- Restraints
Answer: B) Constraints
Explanation:
To ensure database integrity, a set of rules known as constraints is specified.
Discuss this Question
47. An index is a collection of pointers that can refer to rows in a table.
- Pointer
- Index
- Score
- key
Answer: B) Index
Explanation:
An index is a collection of pointers that can refer to rows in a table.
Discuss this Question
48. How many types of indexes are there?
- 4
- 3
- 2
- 1
Answer: C) 2
Explanation:
Types of indexes: Unique and clustered.
Discuss this Question
49. A trigger is a series of activities, which are done for reacting to an INSERT, UPDATE, or DELETE operation on a particular table in the database.
- Events
- Triggers
- Actions
Answer: B) Triggers
Explanation:
A trigger is a series of activities, which are done for reacting to an INSERT, UPDATE or DELETE operation on a particular table in the database.
Discuss this Question
50. How many types of triggers are there?
- 5
- 4
- 3
- 2
Answer: D) 2
Explanation:
There are two types of triggers: Before triggers and After triggers.
Discuss this Question
51. A ____ is a software function that creates integer numbers in either ascending or descending order, within a specific range, to generate a primary key and coordinate other keys within the table.
- Pattern
- Ranks
- Sequence
Answer: C) Sequence
Explanation:
A sequence is a software function that creates integer numbers in either ascending or descending order, within a specific range, to generate a primary key and coordinate other keys within the table.
Discuss this Question
52. How many types of sequences are there?
- 4
- 5
- 2
- 3
Answer: C) 2
Explanation:
There are two types of sequence: NEXTVAL and PREVIOUS VALUE.
Discuss this Question
53. In which of the following sequence type an incremented value for a sequence number is returned?
- NEXTVAL
- PREVIOUS VALUE.
Answer: A) NEXTVAL
Explanation:
In the NEXTVAL sequence type an incremented value for a sequence number is returned.
Discuss this Question
54. ____ is not a genuine table and it does not have any permanent storage.
- View
- Schema
- Fields
Answer: A) View
Explanation:
View is not a genuine table and it does not have any permanent storage.
Discuss this Question
55. ____ type of logging is a mechanism in which existing transaction logs are rewritten when a new transaction log file is required, hence erasing log file sequences and reusing them.
- Archive logging
- Shutter logging
- Circular logging
Answer: C) Circular logging
Explanation:
Circular logging is a mechanism in which existing transaction logs are rewritten when a new transaction log file is required, hence erasing log file sequences and reusing them.
Discuss this Question
56. ____ type of logging mode allows Online Backup as well as database recovery using log files, known as roll-forward recovery.
- Archive logging
- Shutter logging
- Circular logging
Answer: A) Archive logging
Explanation:
Archive logging mode allows Online Backup as well as database recovery using log files, known as roll-forward recovery.
Discuss this Question
57. A role can own a database object?
- True
- False
Answer: B) False
Explanation:
A role cannot own the database objects.
Discuss this Question
58. A ____ is a database object that has a collection of rights that may be assigned to users, groups, PUBLIC, or other roles using the GRANT statement.
- Group
- Role
- Job
- Task
Answer: B) Role
Explanation:
A role is a database object that has a collection of rights that may be assigned to users, groups, PUBLIC, or other roles using the GRANT statement.
Discuss this Question
59. How many types of LDAP are there?
- 4
- 5
- 3
- 2
Answer: D) 2
Explanation:
There are two types of LDAP: Transparent and plugin.
Discuss this Question
60. What is LDAP?
- Lightweight directory access protocol
- Long directory access protocol
- Lengthy directory access protocol
Answer: A) Lightweight directory access protocol
Explanation:
LDAP stands for lightweight directory access protocol.
Discuss this Question