Oracle SQL Associate DDL and DML Operations Quiz

Reviewed by Editorial Team
The ProProfs editorial team is comprised of experienced subject matter experts. They've collectively created over 10,000 quizzes and lessons, serving over 100 million users. Our team includes in-house content moderators and subject matter experts, as well as a global network of rigorously trained contributors. All adhere to our comprehensive editorial guidelines, ensuring the delivery of high-quality content.
Learn about Our Editorial Process
| By Thames
T
Thames
Community Contributor
Quizzes Created: 11982 | Total Attempts: 187,298
| Attempts: 12 | Questions: 20 | Updated: Aug 15, 2026
Please wait...
Question 1 / 21
🏆 Rank #-- ▾
0 %
0/100
Score 0/100

1. What is the primary purpose of the ALTER TABLE statement?

Explanation

ALTER TABLE changes a table’s definition or properties, such as adding, removing, or modifying columns and constraints. It is used to adjust the table’s structure, rather than insert rows, delete table data, or create a backup.

Submit
Please wait...
About This Quiz
Oracle SQL Associate DDL and DML Operations Quiz - Quiz

This quiz evaluates your understanding of DDL (Data Definition Language) and DML (Data Manipulation Language) operations in Oracle SQL. You'll test your knowledge of CREATE, ALTER, DROP statements, INSERT, UPDATE, DELETE, and SELECT commands essential for database management. Perfect for college-level learners preparing for Oracle certification or strengthening SQL fundamentals.

2.

What first name or nickname would you like us to use?

You may optionally provide this to label your report, leaderboard, or certificate.

2. Which command removes an entire table and its data from the database?

Explanation

`DROP TABLE` removes the table itself, along with all its data and structure, from the database. By contrast, `DELETE` and `TRUNCATE` remove rows while leaving the table in place; `REMOVE TABLE` is not a standard SQL command.

Submit

3. Which DDL statement is used to create a new table in Oracle?

Explanation

`CREATE TABLE` is the Oracle DDL statement used to define and create a new table, including its columns and data types. `INSERT TABLE` is not a valid statement; `ALTER TABLE` modifies an existing table, while `DROP TABLE` removes one.

Submit

4. The ______ constraint ensures that all values in a column are unique.

Explanation

The UNIQUE constraint prevents duplicate values from being entered in a column, ensuring each value is distinct. Database systems may differ in how they handle NULL values under this constraint.

Submit

5. What does the COMMIT command do?

Explanation

COMMIT finalizes the current transaction, making its changes permanent in the database. After it runs, those changes can no longer be undone with a transaction rollback.

Submit

6. Which keyword is used to add a new column to an existing table?

Explanation

Use `ALTER TABLE` to modify an existing table, and `ADD` to define the new column, for example: `ALTER TABLE table_name ADD column_name data_type;`

Submit

7. What is a PRIMARY KEY constraint?

Explanation

A PRIMARY KEY constraint ensures that each row in a table can be uniquely identified. Its values must be unique across rows and cannot be NULL, so every record has a valid, distinct identifier.

Submit

8. In a CREATE TABLE statement, which keyword defines a column that must have a value?

Explanation

`NOT NULL` is the SQL constraint that prevents a column from containing a `NULL` value, requiring a value to be provided for that column.

Submit

9. Which statement is used to remove specific rows from a table?

Explanation

The DELETE statement removes selected rows from a table, typically using a WHERE clause to specify which records meet the condition. Without a WHERE clause, it removes every row while leaving the table structure intact. DROP removes the table itself, and TRUNCATE removes all rows rather than targeting specific records.

Submit

10. Which of the following is a valid way to insert multiple rows in Oracle?

Explanation

Oracle does not support the comma-separated multi-row `VALUES` syntax shown in option A. You can insert rows using separate `INSERT` statements, as in B, or use a multitable `INSERT ALL` statement with a `SELECT` source, as in C. Thus, both B and C are valid ways to insert multiple rows.

Submit

11. Which command is used to modify an existing table's structure in Oracle?

Explanation

`ALTER TABLE` changes the structure of an existing Oracle table. It can be used to add, modify, or drop columns, and to change constraints or other table properties. `UPDATE TABLE` is not the command for structural changes; `UPDATE` modifies data in existing rows.

Submit

12. DML transactions can be rolled back using the ROLLBACK command. True or False?

Explanation

True. DML commands such as INSERT, UPDATE, and DELETE modify data within a transaction. If those changes have not been committed, the ROLLBACK command can undo them and restore the data to its previous state.

Submit

13. Can you use a WHERE clause with an INSERT statement?

Explanation

A `WHERE` clause is not used directly with a basic `INSERT ... VALUES` statement. It filters rows in statements such as `SELECT`, `UPDATE`, and `DELETE`. With `INSERT ... SELECT`, a `WHERE` clause can filter the rows selected for insertion, but it belongs to the `SELECT` query.

Submit

14. Which constraint ensures that values in a column match values in another table?

Explanation

A FOREIGN KEY constraint links a column to a key in another table. It ensures that each non-null value in the column matches an existing referenced value, helping maintain referential integrity between the tables.

Submit

15. In Oracle, DDL statements are automatically committed. True or False?

Explanation

True. In Oracle, DDL statements such as `CREATE`, `ALTER`, and `DROP` cause an implicit commit. Oracle commits any pending transaction before executing the DDL and commits again after a successful execution, so those changes cannot be rolled back as part of the earlier transaction.

Submit

16. What does the UPDATE statement do in Oracle SQL?

Explanation

The UPDATE statement changes values in existing rows of a table. It can modify selected rows using a WHERE clause, or affect every row if no condition is specified.

Submit

17. Which DML statement is used to add new rows to a table?

Explanation

INSERT adds new rows of data to a table. UPDATE modifies existing rows, SELECT retrieves data, and ALTER changes a table’s structure.

Submit

18. What is the difference between DELETE and TRUNCATE?

Explanation

DELETE typically removes rows individually, often allowing a condition to target specific records, so it can take longer on large tables. TRUNCATE clears all rows in one operation and is generally faster. Whether TRUNCATE can be rolled back depends on the database system, though some systems restrict rollback or impose other limitations.

Submit

19. The ______ clause is used to sort query results in ascending or descending order.

Explanation

The ORDER BY clause arranges query results according to one or more columns. Use ASC for ascending order or DESC for descending order. If neither is specified, results are sorted in ascending order by default.

Submit

20. The ______ statement retrieves data from one or more tables.

Explanation

The SELECT statement is used to retrieve data from one or more database tables. It can return all columns or specified columns and can use clauses such as WHERE to filter rows and ORDER BY to sort results.

Submit
×
Saved
Thank you for your feedback!
View My Results
Cancel
  • All
    All (20)
  • Unanswered
    Unanswered ()
  • Answered
    Answered ()
What is the primary purpose of the ALTER TABLE statement?
Which command removes an entire table and its data from the database?
Which DDL statement is used to create a new table in Oracle?
The ______ constraint ensures that all values in a column are unique.
What does the COMMIT command do?
Which keyword is used to add a new column to an existing table?
What is a PRIMARY KEY constraint?
In a CREATE TABLE statement, which keyword defines a column that must...
Which statement is used to remove specific rows from a table?
Which of the following is a valid way to insert multiple rows in...
Which command is used to modify an existing table's structure in...
DML transactions can be rolled back using the ROLLBACK command. True...
Can you use a WHERE clause with an INSERT statement?
Which constraint ensures that values in a column match values in...
In Oracle, DDL statements are automatically committed. True or False?
What does the UPDATE statement do in Oracle SQL?
Which DML statement is used to add new rows to a table?
What is the difference between DELETE and TRUNCATE?
The ______ clause is used to sort query results in ascending or...
The ______ statement retrieves data from one or more tables.
play-Mute sad happy unanswered_answer up-hover down-hover success oval cancel Check box square blue
Alert!