nerdexam
Oracle

1Z0-873 · Question #31

Which of the following statements are true for the MERGE storage engine?

The correct answer is A. It uses table-level locking. C. Underlying MyISAM tables are read-locked when you issue a SELECT statement on a MERGE F. Underlying MyISAM tables are write-locked when you issue a statement that modifies a MERGE G. To LOCK a MERGE table, it is sufficient to lock just that table. The MERGE storage engine uses table-level locking. However, because a MERGE table is defined in terms of other tables, MERGE locking involves locks on those tables as well: When the MERGE engine acquires a lock for a MERGE table, it acquires a lock for all the underlying MyISAM…

MySQL Storage Engines

Question

Which of the following statements are true for the MERGE storage engine?

Options

  • AIt uses table-level locking.
  • BIt uses row-level locking.
  • CUnderlying MyISAM tables are read-locked when you issue a SELECT statement on a MERGE
  • DUnderlying MyISAM tables are write-locked when you issue a SELECT statement on a MERGE
  • EUnderlying MyISAM tables are read-locked when you issue a statement that modifies a MERGE
  • FUnderlying MyISAM tables are write-locked when you issue a statement that modifies a MERGE
  • GTo LOCK a MERGE table, it is sufficient to lock just that table.
  • HTo LOCK a MERGE table, you need to lock all underlying MyISAM tables as well.

How the community answered

(15 responses)
  • A
    80% (12)
  • B
    13% (2)
  • E
    7% (1)

Explanation

The MERGE storage engine uses table-level locking. However, because a MERGE table is defined in terms of other tables, MERGE locking involves locks on those tables as well: When the MERGE engine acquires a lock for a MERGE table, it acquires a lock for all the underlying MyISAM tables. Thus, all the tables are locked together. The underlying MyISAM tables are read-locked when you issue a SELECT statement for a MERGE table. The underlying MyISAM tables are write-locked when you issue a statement that modifies a MERGE table, such as INSERT or DELETE. To explicitly lock a MERGE table with LOCK TABLES, it is sufficient to lock just that table. You need not lock the underlying MyISAM tables as well.

Topics

#MERGE storage engine#table locking#underlying MyISAM tables#MERGE locking behavior

Community Discussion

No community discussion yet for this question.

Full 1Z0-873 Practice