SQL and PL/SQL Fundamentals
Quiz covering SQL commands, functions, PL/SQL programming, cursors, triggers, and database management concepts
Questions
If you use the CREATE DATABASE statement on an existing database, all data in the datafiles will be lost.
- True
- False
The ALTER TRIGGER command can be used to change the definition of an existing trigger.
- True
- False
PDoees PL/SQL stands for Procedural Language extension of SQL
- True
- False
What is the syntax of select .... into statement
- SELECT row_name INTO variable_name FROM table_name [WHERE condition];
- SELECT column_name INTO variable_name FROM table_name [WHERE condition];
- SELECT column_name INTO variable_name FROM table_name [WHEN condition];
- SELECT table_name INTO variable_name FROM table_name [WHERE condition];
The Syntax to declare a record of a User-defined datatype is:
- table_name record_type_name;
- column_name record_type_name;
- record_type_name record_name;
- record_name record_type_name;
There are ______ types of loops in PL/SQL
- 1
- 3
- 2
- 4
Which of the following is not a way to execute stored functions
- EXECUTE [or EXEC] database.function_name;
- employee_name := employer_details_func;
- SELECT employer_details_func FROM dual;
- dbms_output.put_line(employer_details_func);
SQL%ISOPEN attribute always returns null in implicit Cursors.
- True
- False
Implicit Cursors are created by users in PL/SQL block.
- True
- False
Oracle engine creates Cursors for every SELECT statements.
- True
- False
There are 4 attributes of Cursor variables
- True
- False
Explicit Cursors need to be opened in DECLARE section.
- True
- False
Which SQL keyword is used to retrieve a minimum value?
- MIN
- LOW
- DOWN
- LOWER
The table rows are also known as...
- Records
- Fields
- Attributes
- Cardinality
What is the ABS SQL function used for?
- To return the absolute, positive value of a numeric expression.
- To return the average value of a numeric expression.
- To return the maximum value of a numeric expression.
- To return the minimum value of a numeric expression.
Which SQL keyword is used to retrieve only unique values?
- DISTINCTIVE
- UNIQUE
- DISTINCT
- DIFFERENT
What does DML stand for?
- Data Mode Lane
- Data Manipulation language
- Data Model Language
- Different Mode Level
Which of the following commands is used to delete data from a SQL database table?
- DELETE
- UNION
- SELECT
- INSERT
Which of the following is not a SQL keyword or SQL clause?
- UPDATE
- SELECT
- INSERT
- INVERT
There are triggers for…
- insert and delete only
- update and delete only
- update, delete and insert
- insert and update only