MySQL Study Flashcards
The world's most popular open-source transactional relational database powering web applications. Click any card to flip and test your knowledge.
What is the default storage engine in MySQL?
InnoDB is the default storage engine, offering ACID transactions, foreign keys, and row-level locking.
What is the difference between InnoDB and MyISAM?
InnoDB supports transactions, row locking, and foreign keys. MyISAM supports table-level locking only and has no transaction support.
How does ON DUPLICATE KEY UPDATE work in MySQL?
When an INSERT statement causes a primary or unique key duplicate, MySQL executes an UPDATE on the existing row instead.
What is GROUP_CONCAT used for?
GROUP_CONCAT aggregates multiple non-null row values into a single concatenated string per group.
What is the function of the Redo Log in InnoDB?
The Redo Log records page changes to ensure crash recovery (durability) before changes are written to tablespace data files.
What does EXPLAIN in MySQL show?
EXPLAIN displays how MySQL executes a query, including key usage, join types (ALL, ref, eq_ref), and rows examined.
How do AUTO_INCREMENT columns work?
AUTO_INCREMENT automatically generates sequential unique numeric keys for new table rows.
What is Master-Replica Replication in MySQL?
A topology where writes to a Primary database are recorded in binary logs (binlog) and replayed on Secondary replica instances.
What is a Covering Index in MySQL?
An index that contains all columns required by a query, enabling MySQL to return results directly from the index without reading table pages.
What is the default isolation level in InnoDB?
REPEATABLE READ is InnoDB's default isolation level, preventing non-repeatable reads using multi-versioning.
Need practical SQL queries for MySQL?
Explore our ready-to-use copy-paste query recipes in the Cookbook.