Advanced DML & Data Movement MCQs

6 MCQs  — Oracle: Modifying Data & Multiple Databases MCQs

Practice Advanced DML & Data Movement MCQs with correct answers and explanations. These questions are from the Oracle: Modifying Data & Multiple Databases MCQs section.

What does the MERGE statement do?
Joins two databases together
Merges two tablespaces
Deletes duplicate tables
Inserts new rows or updates existing rows in a single statement
In a MERGE statement, which clause handles rows that already exist?
WHEN FOUND THEN INSERT
ON DUPLICATE KEY UPDATE
WHEN MATCHED THEN UPDATE
IF EXISTS THEN UPDATE
Which statement copies rows from one table to another existing table?
COPY t1 TO t2;
MOVE t1 INTO t2;
UPDATE t2 FROM t1;
INSERT INTO t2 SELECT * FROM t1;
What does CREATE TABLE new_emp AS SELECT * FROM emp; do?
Creates a new table with the structure and data of the query
Creates a view
Creates only an empty structure
Renames EMP