0

databases Online Quiz - 82

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

Which two parameters can be set to tell the Oracle to use OMF (Oracle Managed Files)?

  1. DB_CREATE_FILE_DEST

  2. DB_CREATE_ONLINE_LOG_n

  3. USER_DUMP_DEST

  4. LOG_ARCHIVE_DEST


Correct Option: A

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.


Correct Option: B

Which character is used to continue a statement in SQL*Plus?

  1. / '

    • '
    • '
  2. = '


Correct Option: C

AI Explanation

To answer this question, you need to understand how statements are executed in SQL*Plus.

In SQL*Plus, a hyphen (-) character is used to continue a statement onto the next line.

Option A) / ' - This option is incorrect because the forward slash (/) character is used to execute a SQL or PL/SQL statement in SQL*Plus, but it is not used to continue a statement onto the next line.

Option B) * ' - This option is incorrect because the asterisk (*) character is not used to continue a statement in SQL*Plus.

Option C) - ' - This option is correct because the hyphen (-) character is used to continue a statement onto the next line in SQL*Plus.

Option D) = ' - This option is incorrect because the equal sign (=) character is not used to continue a statement in SQL*Plus.

The correct answer is Option C) - '. This option is correct because the hyphen (-) character is used to continue a statement onto the next line in SQL*Plus.

Which Oracle access method is the fastest way for Oracle to retrieve a single row?

  1. Primary key access

  2. Access via unique index

  3. Table access by ROWID

  4. Full table scan


Correct Option: C

To produce a meaningful result set without any cartesian products, what is the minimum number of conditions that should appear in the WHERE clause of a four-table join?

  1. 8

  2. 3

  3. 2

  4. 4


Correct Option: B

What best describes the relationship between indexes and SQL performance?

  1. Indexes are only used in special cases

  2. Indexes are used to make table storage more efficient

  3. Indexes rarely make a difference in SQL performance

  4. Indexes exist solely to improve query speed


Correct Option: D
  1. SQL cannot support object-orientation

  2. The same query can be written in many ways, each with vastly different execution plans.

  3. SQL syntax is too difficult for non-computer professionals to use

  4. SQL creates excessive locks within the database


Correct Option: B
  1. The user had to have knowledge of the table and index structures

  2. Navigational data access was far slower than declarative access.

  3. Navigational access languages required the coder to embed their queries inside a procedural language shell.

  4. Navigational languages were far slower then SQL


Correct Option: A

Which of the following are valid table-partitioning methods?

  1. Range

  2. Freelist

  3. Hash

  4. Index


Correct Option: C

INTERVAL PARTITIONING IS NOT SUPPORTED FOR INDEX-ORGANIZED TABLES.

  1. True

  2. False


Correct Option: A

CAN WE SPECIFY MULITPLE PARTITIONING KEY COLUMNS IN INTERVAL PARTITIONING TECHNIQUE

  1. True

  2. False


Correct Option: B

CAN WE SPECIFY VARCHAR DATATYPE FOR THE PARTITIONING KEY IN INTERVAL PARTITIONING TECHNIQUE

  1. True

  2. False


Correct Option: B

IS IT POSSIBLE TO SPECIFY THE EXECUTION ORDER OF TRIGGERS IN ORACLE 10G

  1. True

  2. False


Correct Option: B

REGEXP_COUNT TAKES STRING AND REGULAR EXPRESSION AND RETURNS NUMBER OF TIMES THE EXPRESSION IS PRESENT IN THE STRING

  1. True

  2. False


Correct Option: A

INTERVAL PARTITIONING IS A PARTITIONING TECHNIQUE BASED ON

  1. HASH

  2. MODULUS

  3. RANGE

  4. RANDOM


Correct Option: C
  1. FOR EACH ROW trigger on the EMP table

  2. Statement-level Trigger on the EMP table

  3. FOR EACH ROW trigger on the AUDIT_TABLE table

  4. Statement-level Trigger on the AUDIT_TABLE


Correct Option: A
  1. Trigger type

  2. Trigger body

  3. Trigger event

  4. Trigger Timing


Correct Option: A

Examine this code CREATE OR REPLACE TRIGGER SECURE_emp BEFORE LOGON ON EMP BEGIN ............. END WHAT TYPE OF TRIGGER IS IT ?

  1. DML trigger

  2. Invalid Trigger

  3. Application Trigger

  4. System Event trigger


Correct Option: B

AI Explanation

To determine the type of trigger in the given code, let's examine the options:

A. DML trigger - DML triggers are used to execute specific actions before or after data manipulation language (DML) statements, such as INSERT, UPDATE, or DELETE. However, the code provided does not specify any DML statements, so this option is incorrect.

B. Invalid Trigger - This option is correct. The code is incomplete and does not contain any specific logic or actions inside the trigger. Therefore, it is an invalid trigger.

C. Application Trigger - Application triggers are custom triggers that are specifically designed for a particular application. The given code does not provide any information suggesting that it is an application trigger, so this option is incorrect.

D. System Event Trigger - System event triggers are triggered by system-level events, such as system startup or shutdown. The given code does not specify any system events, so this option is incorrect.

Therefore, the correct answer is B. Invalid Trigger. The code provided is incomplete and does not contain any specific logic or actions inside the trigger.

CREATE OR REPLACE TRIGGER update_emp AFTER UPDATE ON EMP BEGIN INSERT INTO AUDIT_TABLE values(user ,sysdate ); END ; you issue an update command in the EMP tables that result in a update of 10 rows. How many rows are inserted into the AUDIT_TABLE ?

  1. 1

  2. 10

  3. none

  4. Value equal to number of rows in EMP table


Correct Option: A

AI Explanation

To answer this question, let's go through each option to understand why it is correct or incorrect:

Option A) 1 - This option is correct because the trigger update_emp is fired after an update is performed on the EMP table. The trigger inserts a single row into the AUDIT_TABLE with the value of the user and the current date and time. Since the trigger is fired only once, regardless of the number of rows updated, only one row will be inserted into the AUDIT_TABLE.

Option B) 10 - This option is incorrect because the trigger only inserts one row into the AUDIT_TABLE, regardless of the number of rows updated in the EMP table.

Option C) none - This option is incorrect because the trigger does insert a row into the AUDIT_TABLE after the update on the EMP table.

Option D) Value equal to the number of rows in the EMP table - This option is incorrect because the trigger only inserts one row into the AUDIT_TABLE, regardless of the number of rows in the EMP table.

The correct answer is A) 1. This option is correct because the trigger update_emp inserts a single row into the AUDIT_TABLE regardless of the number of rows updated in the EMP table.

- Hide questions