100% found this document useful (2 votes)
2K views

ORCL - SQL Explorer Exam

The document contains questions about SQL statements and concepts like data definition statements, data manipulation statements, entity relationship modeling, and database objects like the DUAL table. The questions cover topics like the components of SQL statements, the purpose of clauses like SELECT, FROM, WHERE, data types, NULL values, and features of tools like Oracle SQL Developer.
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
100% found this document useful (2 votes)
2K views

ORCL - SQL Explorer Exam

The document contains questions about SQL statements and concepts like data definition statements, data manipulation statements, entity relationship modeling, and database objects like the DUAL table. The questions cover topics like the components of SQL statements, the purpose of clauses like SELECT, FROM, WHERE, data types, NULL values, and features of tools like Oracle SQL Developer.
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 5

1.

Examine this employee table's column definitions:

empid number primary key


empname varchar2(50)

Which SELECT statement displays all employee table columns?

SELECT FROM employee;


SELECT * FROM employee;
SELECT *.* FROM employee;
SELECT "empid", "empname" from employee;

2. Examine this statement:

SELECT 3 * 2 + 2 / 4 FROM DUAL;

What is the result?

6.5
6
7.5
3

3. Examine these two rows from an employee table:

empid emp_name designation


------- ----------- -------------
12330 Scott Manager
10012 King CEO

You must display the rows like this:

PROFILE
----------
Scott is a Manager
King is a CEO

Which statements do this? (Choose two)

SELECT CONCAT(emp_name, " is a " + designation)) PROFILE FROM emp;


SELECT CONCAT(emp_name," is a ", designation) PROFILE FROM emp;
SELECT CONCAT(emp_name, concat(' is a ' , designation)) PROFILE FROM emp;
SELECT emp_name || ' is a '|| designation AS PROFILE FROM emp;
SELECT emp_name + ' is a ' + designation AS PROFILE FROM emp;
4. Which statements are true about these SQL statements? (Choose two)

MERGE and UPDATE are both data definition statements.


COMMIT is a data definition statement.
CREATE TABLE is a data definition statement.
ROLLBACK is a transaction control statement.
DROP and DELETE are both data manipulation statements.

5. Which statements are true about SQL statements? (Choose two)

Character literal values must be enclosed within double quotation marks.


The quote (q) operator can be used to escape a “\” in a literal.
Date values must be enclosed within single quotation marks.
The quote (q) operator can be used to display the double quotation mark of a literal, if it contains
a double quote.
Numeric literals must be enclosed within single quotation marks.

6. Which statements are true about Entity Relationship (ER) modelling? (Choose two)

An entity is typically implemented as a database.


An entity exists only physically.
An ER diagram shows the complete logical structure of a database schema.
An ER model creates an ER diagram from business specifications.
An ER diagram is a group of similar entities.

7. What are some of the features of Oracle Database, up to, and including Oracle 19c? (Choose
three)

Client-side data validation


Game playing web application development API features
High availability
Performance-related features
Security

8. Which statements are true about MySQL Workbench? (Choose three)

It is available on Windows, Linux, and Mac OS X.


It requires a paid license.
It is not appropriate for use by DBAs.
It is a cloud-based tool.
It provides data modeling, SQL development, and comprehensive administration tools.
It is a unified visual tool that can be used by developers.
It provides only data modeling capabilities.
9. Which statement is true about SQL statements?

FROM clauses specify the column or columns to be displayed.


They must be terminated by a colon (:).
SELECT clauses identify the table to be queried.
They are not case sensitive.

10. Examine this product table's column definitions:

pid number primary key


pname varchar2(50)

You must display column headings as shown:

Product_ID Product Name

Which SELECT statement does this?

SELECT pid AS Product_ID, pname AS Product Name FROM product;


SELECT pid @Product_ID, pname @"Product Name" FROM product;
SELECT pid Product_ID, pname Product Name FROM product;
SELECT pid Product_ID, pname "Product Name" FROM product;

11. Examine these employee table rows:

empid empname designation


------- ----------- -------------
12330 Scott Manager
10012 King CEO
15235 James Manager
15323 Kent CTO
15124 Scott CMO

Now examine this statement:

SELECT DISTINCT empname FROM employee;

In what order are the empnames displayed?

Scott, King, James, Kent, Scott


Scott, Scott
James, Kent, King, Scott
Scott, King, James, Kent
12. Which are DDL statements? (Choose three)

ROLLBACK
SAVEPOINT
DROP
TRUNCATE
GRANT
COMMIT
CREATE

13. Which statement is true about an arithmetic expression referring to columns with NULLs?

It evaluates to TRUE.
It evaluates to NULL.
It evaluates to FALSE.
It evaluates to 0.

14. Which statements are true about Oracle SQL Developer? (Choose two)

It can be used in Oracle Cloud deployments.


It supports web page design.
It requires a paid license for each terminal.
It can be used in traditional Oracle deployments at a customer site.
It requires a paid license for each user.

15. Which command produces output that displays the structure of a table?

CREATE
SELECT
SHOW
ALTER
DESCRIBE

16. Which statement is true about entities in an Entity Relationship (ER) diagram?

The primary key must be prefixed by an asterisk.


They must have at least one foreign key for each attribute per entity.
They must have a primary key.
They must have at least one foreign key per entity.
17. Which are DML statements? (Choose three)

COMMIT
UPDATE
DELETE
INSERT
DROP
TRUNCATE
CREATE

18. Which statements are true about SQL? (Choose two)

It can process multiple data rows with a single command.


It is an abbreviation for Standard Query Language.
It can be used only for retrieving data from hierarchical databases.
It manages data only at the physical level.
It can be used to insert, retrieve, and modify data in relational tables.

19. Which statements are true about the DUAL table? (Choose two)

It contains exactly one column of type varchar2(1) named DUMMY.


It has only one row and that row is NULL.
It contains exactly one column of type varchar2(1) named DUAL.
It is a temporary table.
It has only one row and that row has the value 'x'.

20. Which statements are true about Entity Relationship (ER) modelling? (Choose two)

An ER diagram is a group of similar entities.


An entity is typically implemented as a database.
An entity exists only physically.
An ER model creates an ER diagram from business specifications.
An ER diagram shows the complete logical structure of a database schema.

21. In a SQL statement, which clause states the conditions for row selection?

FROM
ORDER BY
WHERE
SELECT

You might also like