0

databases Online Quiz - 105

Description: databases Online Quiz - 105
Number of Questions: 20
Created by:
Tags: databases
Attempted 0/20 Correct 0 Score 0
  1. 4000 / 4000

  2. 4000 / 32767

  3. 2000 / 4000

  4. None of these


Correct Option: B

Default type of compilation in Oracle

  1. INTERPRETTED

  2. NATIVE

  3. BOTH

  4. None of these


Correct Option: B

A Package spec is compulsory but a package Body is not compulsory

  1. True

  2. False


Correct Option: A

For a certain row ina table, a VARCHAR2 coilumn contains the value TCSLTD, padded to the right with seven spaces by the application when the length() function processes the coplumn value , what will be the value returned

  1. 6

  2. 13

  3. 30

  4. 60


Correct Option: B

Dropping of table has which of the following effects on the non unique index created on the table

  1. no effect

  2. The Index will be dropped

  3. The index will become unusable

  4. the index will have NULLvalues

  5. You cannot drop a table until you drop the index


Correct Option: B

Which of the following requires correlated subquery

  1. IN

  2. BETWEEN

  3. LIKE

  4. EXISTS


Correct Option: D

Which of the following is a valid statement for Sequences

  1. IDENTIFIED BY

  2. USING TEMPORARY TABLESPACE

  3. MAXVALUE

  4. ON DELETE CASCADE

  5. CURRVAL

  6. NEXTVAL


Correct Option: C

Can we modify Primary key constraint

  1. True

  2. False


Correct Option: A

Select the incorrect statement

  1. alter table table1 rename column column1 to column2

  2. alter table table1 rename to table 2

  3. alter table table1 add (c1 char(10))

  4. alter table table1 enable constraint t1_pk


Correct Option: D

We can update the value of the columns that is selected on view list

  1. yes always

  2. yes on simple views with group by

  3. no on simple views with group by and distinct clause

  4. yesy on complex views


Correct Option: C

The Default indexing system in oracle

  1. BALANCED TREE

  2. BITMAP

  3. FUNCTIONAL

  4. BINARY TREE


Correct Option: A

An Equi join can be:

  1. Natural join

  2. Inner Join

  3. Both

  4. Cross Join


Correct Option: C

Which index will be beneficial to create on the column Gender of a table name employee which permits entry of only two values (M/F)?

  1. Compressed Index

  2. Function based Index

  3. Bitmap Index

  4. B*-Tree index


Correct Option: C

Which type of join is this?

  1. Left Outer Join

  2. Right outer Join

  3. Full Outer Join

  4. Inner Join


Correct Option: A

Which is not a valid join?

  1. Equi Join

  2. Natural Join

  3. Left Inner Join

  4. Cartesian product


Correct Option: C

There are 10 rows in Table A and 0 Rows in table B. If you fire the following query:

  1. 10

  2. 0

  3. 1

  4. Syntax Error


Correct Option: B

What does the following query Do?

  1. Null

  2. The Null values of COMMISSION column will be displayed as Null after addition to sal

  3. The Null values of COMMISSION column will be changed to 0 & will be added to sal

  4. Syntax error


Correct Option: C

Examine the SQL Statements that creates ORDERS table: For which columns would an index be automatically created when you execute the above SQL statement?

  1. ) SER_NO, PROD_ID_NUMBER

  2. ORDER_ID and ORDER_DATE

  3. SER_NO, Composite index on ORDER_ID and ORDER_DATE

  4. SER_NO, ORDER_ID and ORDER_DATE


Correct Option: C

AI Explanation

To answer this question, we need to understand the concept of indexes in SQL.

Indexes are used to improve the performance of queries by allowing the database to quickly find and retrieve specific rows based on the values in certain columns. When a table is created, indexes can be manually specified by the user, or they can be automatically created by the database management system (DBMS) based on certain criteria.

In the given SQL statement that creates the ORDERS table, the columns specified are:

SER_NO PROD_ID_NUMBER ORDER_ID ORDER_DATE

Out of these columns, an index would be automatically created for the composite index on ORDER_ID and ORDER_DATE.

Option C) SER_NO, Composite index on ORDER_ID and ORDER_DATE - This option is correct because a composite index on ORDER_ID and ORDER_DATE would be automatically created.

Therefore, the correct answer is option C.

- Hide questions