databases Online Quiz - 201

databases Online Quiz - 201

20 Questions Published

Questions

Question 1 True/False

It is possible to use Transactional control statements in Database Triggers?

  1. True
  2. False
Question 2 Multiple Choice (Single Answer)

Which of the following is not correct about Cursor ?

  1. Cursor is a named Private SQL area
  2. Cursor holds temporary results
  3. Cursor is used for retrieving multiple rows
  4. SQL uses implicit Cursors to retrieve rows
Question 3 Multiple Choice (Single Answer)

Which of the following is NOT VALID in PL/SQL ?

  1. Select … into
  2. Update
  3. Create
  4. Delete
Question 4 Multiple Choice (Single Answer)

A Transaction ends

  1. Only when it is Committed
  2. Only when it is Rolledback
  3. When it is Committed or Rolledback
  4. None of the above
Question 5 Multiple Choice (Single Answer)

Which command or action causes an automatic rollback?

  1. GRANT
  2. EXIT at pl/sql prompt
  3. Alter command
  4. System crash
  5. Commit before a system crash
Question 6 True/False

If an UNIQUE KEY constraint on DATE column is created, it will accept the rows that are inserted with SYSDATE ?

  1. True
  2. False
Question 7 Multiple Choice (Single Answer)

Why is searching for large-table full-table scans critical to SQL tuning?

  1. They indicate an optimized execution plan.
  2. They may be able to be tuned to use an index
  3. The full-table scan should be normalized from the database design
  4. A full-table scan is always sub-optimal.
Question 8 Multiple Choice (Single Answer)

IDMS is a ______________ type of database

  1. Relational
  2. Hierarchical
  3. Network
  4. What is IDMS
Question 9 Multiple Choice (Single Answer)

What is IDMS?

  1. Intergrated Data Management System
  2. India Department of Management Studies
  3. International Data Management System
  4. Integrated Data Management Services
Question 10 Multiple Choice (Single Answer)

READY command is for _______

  1. VOLUME
  2. AREA
  3. RECORD
  4. PAGE
Question 11 Multiple Choice (Single Answer)

BIND is for ________

  1. AREA
  2. VOLUME
  3. PAGE
  4. RECORD
Question 12 True/False

READY follows BIND (TRUE/FALSE)

  1. True
  2. False
Question 13 Multiple Choice (Single Answer)

Which of the following DB2 command can be used to change bob’s password?

  1. CHANGE PASSWORD USER bob OLD bobpass NEW newpass
  2. CONNECT TO sample USER bob USING bobpass NEW newpass
  3. CONNECT TO sample USER bob USING bobpass NEW newpass CONFIRM newpass
  4. No DB2 command can be used to change the password of a user ID
Question 14 Multiple Choice (Single Answer)

Which of the following privilege is required to create a new package in a database?

  1. CONTROL
  2. BIND
  3. EXECUTE
  4. BINDADD
Question 15 Multiple Choice (Single Answer)

Which of the following system catalog view contains the grantee information of the REFERENCE privilege on a view?

  1. SYSCAT.VIEWS
  2. SYSCAT.TABLES
  3. SYSCAT.TABAUTH
  4. SYSCAT.REFERENCES
Question 16 Multiple Choice (Single Answer)

Which of the following statement is true?

  1. a table is an ordered set of data records
  2. an index always accesses data in ascending order
  3. a view stores the data on a different tablespace
  4. an index can be used to enforce uniqueness in a table
Question 17 Multiple Choice (Multiple Answers)

CREATE DATABASE command creates some default table spaces. What are they? Choose all that apply.

  1. SYSLOGSPACE
  2. TEMPSPACE1
  3. USERSPACE1
  4. SYSCATSPACE
Question 18 Multiple Choice (Single Answer)

What keyword is used to define the number of pages that the database will write to one container before skipping to the next container?

  1. SKIPSIZE
  2. PREFETCHSIZE
  3. STRIPSIZE
  4. EXTENTSIZE
Question 19 Multiple Choice (Single Answer)

Examine the description of the EMPLOYEES table: EMP_ID NUMBER(4) NOT NULL LAST_NAME VARCHAR2(30) NOT NULL FIRST_NAME VARCHAR2(30) DEPT_ID NUMBER(2) JOB_CAT VARCHARD2(30) SALARY NUMBER(8,2) Which statement shows the maximum salary paid in each job category of each department?

  1. SELECT dept_id, job_cat, MAX(salary) FROM employees WHERE salary > MAX(salary);
  2. SELECT dept_id, job_cat, MAX(salary) FROM employees GROUP BY dept_id, job_cat;
  3. SELECT dept_id, job_cat, MAX(salary) FROM employees;
  4. SELECT dept_id, job_cat, MAX(salary) FROM employees GROUP BY dept_id;
Question 20 Multiple Choice (Multiple Answers)

Examine the description of the STUDENTS table: STD_ID NUMBER(4) COURSE_ID VARCHARD2(10) START_DATE DATE END_DATE DATE Which two aggregate functions are valid on the START_DATE column? (Choose two)

  1. SUM(start_date)
  2. COUNT(start_date)
  3. AVG(start_date, end_date)
  4. MIN(start_date)