0

databases Online Quiz - 78

Description: databases Online Quiz - 78
Number of Questions: 20
Created by:
Tags: databases
Attempted 0/20 Correct 0 Score 0

USER1 is the owner of TABLE1. Assuming USER1 only holds privileges for TABLE1, which of the following is the best way to remove all privileges USER1 holds?

  1. REVOKE CONTROL ON table1 FROM user1

  2. REVOKE ALL PRIVILEGES ON table1 FROM user1

  3. REVOKE CONTROL ON table1 FROM user1; REVOKE ALL PRIVILEGES ON table1 FROM user1

  4. REVOKE CONTROL, ALL PRIVILEGES ON table1 FROM user1


Correct Option: C

Which authority or privilege is granted by the DB2 Database Manager configuration file?

  1. CONNECT

  2. CONTROL

  3. SYSMAINT

  4. EXECUTE


Correct Option: C
  1. GRANT ALTER ON TABLE department TO user1

  2. GRANT ALTER (dept_name) ON TABLE department TO user1

  3. GRANT UPDATE ON TABLE department TO user1

  4. GRANT UPDATE (dept_name) ON TABLE department TO user1


Correct Option: D
  1. GRANT DROP ON INDEX empid_x TO user1

  2. GRANT DELETE ON INDEX empid_x TO user1

  3. GRANT INDEX ON TABLE employee TO user1

  4. GRANT CONTROL ON INDEX empid_x TO user1


Correct Option: D
  1. Gives user USER1 the ability to refer to COL1 and COL2 of table TABLE1 in queries, along with the ability to give this authority to other users and groups.

  2. Gives user USER1 the ability to refer to COL1 and COL2 of table TABLE1 in views, along with the ability to give this authority to other users and groups.

  3. Gives user USER1 the ability to define a referential constraint on table TABLE1 using columns COL1 and COL2 as the parent key of the constraint.

  4. Gives user USER1 the ability to define a referential constraint on table TABLE1 using columns COL1 and COL2 as the foreign key of the constraint.


Correct Option: C

Assume PUBLIC has been granted all privileges on table T1, which of the following statements would continue to permit any user to add rows to table T1 but not remove them?

  1. REVOKE DROP ON T1 FROM PUBLIC

  2. REVOKE UPDATE ON T1 FROM PUBLIC

  3. REVOKE DELETE ON T1 FROM PUBLIC

  4. REVOKE CONTROL ON T1 FROM PUBLIC


Correct Option: C
Explanation:

To solve this question, the user needs to know the basics of database management and the concept of privileges.

Option A: REVOKE DROP ON T1 FROM PUBLIC - This option revokes the privilege to drop (delete) the entire table T1. It doesn't address the issue of adding rows. Therefore, this option is incorrect.

Option B: REVOKE UPDATE ON T1 FROM PUBLIC - This option revokes the privilege to update existing rows in the table T1. This means that the user cannot change the data in the rows that already exist in the table. It does not address the issue of adding rows. Therefore, this option is incorrect.

Option C: REVOKE DELETE ON T1 FROM PUBLIC - This option revokes the privilege to delete rows from the table T1. This means that the user cannot remove rows from the table. However, the user can still add rows to the table. Therefore, this option is correct.

Option D: REVOKE CONTROL ON T1 FROM PUBLIC - This option revokes all privileges from the PUBLIC on table T1, including the ability to add rows. Therefore, this option is incorrect.

The Answer is: C

A DRDA host database resides on a z/OS or an i5/OS and listens on port 446. The TCP/IP address for this system is 192.168.10.1 and the TCP/IP host name is myhost. Which of the following commands is required to update the local node directory so that a DB2 client can access this DRDA database?

  1. CATALOG TCPIP NODE myhost REMOTE db2srv SERVER 446

  2. CATALOG TCPIP NODE mydb2srv REMOTE myhost SERVER 446

  3. CATALOG TCPIP NODE myhost REMOTE db2srv SERVER 192.168.10.1

  4. CATALOG TCPIP NODE mydb2srv REMOTE myhost SERVER 192.168.10.1


Correct Option: B

A “trusted” client needs to communicate with a server that has been configured to Use CLIENT Authentication. Which of the following will be used to verify passwords?

  1. User ID/Password File

  2. Communications Layer

  3. Client Applications

  4. Operating Systems


Correct Option: D
  1. Control Center

  2. Development Center

  3. Developer Work Bench

  4. Stored Procedure Builder


Correct Option: C

which of the following tools is used to analyze all of the database operations by an application against a DB2 for i5/OS database?

  1. Visual Explain

  2. Activity Monitor

  3. SQL Performance Monitor

  4. DB2 Performance Monitor


Correct Option: C

Which of the following privileges permit a user to update the comment on sequence?

  1. Control

  2. Update

  3. Usage

  4. Later


Correct Option: D

AI Explanation

To answer this question, we need to understand the privileges related to updating comments on a sequence.

Option A) Control - This option is incorrect because the "Control" privilege does not specifically grant permission to update comments on a sequence.

Option B) Update - This option is incorrect because the "Update" privilege typically refers to the ability to update the actual data within a sequence, not the comments associated with it.

Option C) Usage - This option is incorrect because the "Usage" privilege generally refers to the ability to view or query the data within a sequence, not the ability to update comments.

Option D) Later - This option is correct because the "Later" privilege allows a user to update the comment on a sequence. This privilege specifically grants the ability to modify or update the comment associated with a sequence.

Therefore, the correct answer is Option D) Later. This option is correct because it grants the necessary privilege to update the comment on a sequence.

  1. Current

  2. Projected

  3. Historical

  4. Current and Projected


Correct Option: A

On which of the following database objects may the Select Privilege be controlled?

  1. Sequence

  2. Schema

  3. Group

  4. View


Correct Option: D

AI Explanation

To answer this question, we need to understand the concept of privileges in a database.

In a database system, privileges are permissions that control the access and actions that users can perform on database objects. The Select Privilege specifically controls whether a user can retrieve data from a database object.

Let's go through each option to understand why it is correct or incorrect:

Option A) Sequence - Sequences in a database are used to generate unique numeric values. However, the Select Privilege does not apply to sequences as they do not store data that can be retrieved using the SELECT statement.

Option B) Schema - A schema is a logical container for database objects. It does not store data itself, but rather organizes and provides a namespace for objects. The Select Privilege does not apply to schemas because they do not store data to be retrieved.

Option C) Group - A group in a database is a logical collection of users. The Select Privilege cannot be controlled at the group level. Privileges are typically granted to individual users or roles, not groups.

Option D) View - A view is a virtual table that is derived from one or more tables or other views. It presents a subset of the data stored in the underlying tables. The Select Privilege can be controlled on a view because it determines whether a user can retrieve data from the view using the SELECT statement. This makes Option D the correct answer.

Therefore, the correct answer is Option D) View. The Select Privilege can be controlled on views to determine whether users can retrieve data from them.

  1. DB2 AVI Extender

  2. DB2 Text Extender

  3. DB2 XML Extender

  4. DB2 Spatial Extender


Correct Option: C

Which of the following does DB2 Configuration Advisor recommend?

  1. SQL statements

  2. New indexes

  3. DDL

  4. Database configuration parameter settings


Correct Option: D
- Hide questions