Database Links & Distributed Operations MCQs

11 MCQs  — Oracle: Modifying Data & Multiple Databases MCQs  (Page 1 of 2)

Practice Database Links & Distributed Operations MCQs with correct answers and explanations. These questions are from the Oracle: Modifying Data & Multiple Databases MCQs section.

What is a database link in Oracle?
A foreign key between two columns
A schema object that lets you access objects in another database
A backup file
A type of index
Which statement creates a database link?
CREATE LINK remote_db TO 'orcl2';
ALTER DATABASE ADD LINK remote_db;
CONNECT DATABASE remote_db;
CREATE DATABASE LINK remote_db CONNECT TO hr IDENTIFIED BY pwd USING 'orcl2';
How do you query the EMP table on a remote database using the link REMOTE_DB?
SELECT * FROM emp@remote_db;
SELECT * FROM remote_db.emp#;
SELECT * FROM emp->remote_db;
SELECT * FROM remote_db::emp;
What is the difference between a PUBLIC and a private database link?
A PUBLIC link is encrypted; a private link is not
A PUBLIC link works only locally
A PUBLIC link can be used by all users; a private link only by its owner
There is no difference
What is a distributed transaction?
A transaction that runs very long
A transaction that modifies data on two or more databases
A transaction using multiple tables on one database
A transaction without COMMIT
Which protocol ensures a distributed transaction commits or rolls back at all sites?
Two-phase commit (2PC)
Two-factor commit
Single-phase commit
Redo shipping