0

databases Online Quiz - 131

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

If the below block, when you execute then what will be the output? Begin Null; Exception When others then Dbms_output.put_line(‘ I am in Others Exception’); When no_data_found then Dbms_output.put_line(‘ I am in no data found Exception’); End;

  1. I am in Others Exception

  2. I am in no data found Exception

  3. Compilation Error

  4. None of the above


Correct Option: C
  1. Positional & Named

  2. Positional alone

  3. Positional ,Name and Combination

  4. None of the above


Correct Option: C

How can you find within a PL/SQL block, if a cursor is open?

  1. %OPEN

  2. %ISOPEN

  3. 1 & 2

  4. None of the above


Correct Option: B
  1. %ROWTYPE allows you to associate a variable with an entire table row

  2. %ROWTYPE associates a variable with a single column type

  3. Both of the above

  4. None of the above


Correct Option: A

I have just now created sequence abc and If you immediately run the below select statement , what is the output? CREATE SEQUENCE abc MINVALUE 1 MAXVALUE 10 START WITH 1 INCREMENT BY 1 CACHE 20 Select abc.currval from dual;

  1. 1

  2. Null

  3. Error

  4. None of the above


Correct Option: C
  1. SQL%ROWCOUNT, SQL%ISFOUND,SQL%NOTFOUND,SQL%ISOPEN

  2. SQL%ROWCOUNT, SQL%FOUND,SQL%NOTFOUND,SQL%OPEN

  3. SQL%ROWCOUNT, SQL%FOUND,SQL%NOTFOUND,SQL%ISOPEN

  4. All of the above


Correct Option: C
  1. binary

  2. Character

  3. ASCII

  4. All of the above


Correct Option: A

SQL has facility for programmed handling of errors that arise during the manipulation of data.

  1. True

  2. False


Correct Option: B

_________ data type stores unstructured binary data upto 4GB length.

  1. CLOB

  2. BLOB

  3. LONG

  4. All of the above


Correct Option: B

In a PL/SQL block structure, which parts are optional?

  1. DELCARE and BEGIN

  2. DECALRE and EXCEPTION

  3. EXCEPTION and END

  4. BEGIN and END


Correct Option: B

Under which two circumstances do you design database triggers? (Choose two)

  1. To duplicate the functionality of other triggers.

  2. To replicate built-in constraints in the Oracle server such as primary key and foreign key.

  3. To guarantee that when a specific operation is performed, related actions are performed.

  4. For centralized, global operations that should be fired for the triggering statement, regardless of which user or application issues the statement.


Correct Option: C,D

Which of the following are not operators you can use in a math formula within a SQL statement?

  1. +

  2. (

  3. ]

  4. /


Correct Option: C
  1. SELECT column_name ALIAS alias_name FROM table_name;

  2. SELECT column_name alias_name FROM table_name;

  3. SELECT alias_name FROM table_name;

  4. ASSIGN alias_name TO column_name;


Correct Option: B

Which of the following are reasonable series of transaction-control commands?

  1. Insert some records, COMMIT, ROLLBACK

  2. SAVEPOINT, insert some records, ROLLBACK, ROLLBACK, COMMIT

  3. ROLLBACK, insert some records, COMMIT

  4. ROLLBACK, insert some records, COMMIT, COMMIT


Correct Option: C

Which of the following shows the wildcards for a single character and multiple characters, respectively?

  1. ?, *

  2. _, %

  3. ?, _

  4. *, %


Correct Option: B
  1. ROUND(4.5, 0) < TRUNC(4.5, 0)

  2. ROUND(4.1, 0) < TRUNC(4.2, 0

  3. ROUND(8.9, 0) > TRUNC(8.9, 0)

  4. ROUND(8.9, 1) > TRUNC(8.95, 2)


Correct Option: C

A trigger is a special type of stored procedure that is executed by the SQL Server when an Insert, Modify or Delete operation is performed Against a given table.

  1. True

  2. False


Correct Option: A

Stored procedures are the way to create routines and procedures that are run on the server.

  1. True

  2. False


Correct Option: A
- Hide questions