SQL vs NoSQL Databases MCQ 60 Practice Tests With Answers (2026)

SQL vs NoSQL Databases β understanding architectural differences, scaling models (horizontal vs vertical), and consistency trade-offs (CAP Theorem, ACID vs BASE) β is critical for modern database system design. These 60 carefully structured SQL vs NoSQL MCQs take you from basic terminologies to advanced distributed system concepts.
Questions are organized into three progressive levels of 20 questions each: Basics (covering core database definitions, relational tables, schema differences, standard database examples, and scaling models), Concepts (covering CAP Theorem, ACID vs BASE consistency transaction models, sharding patterns, document querying, and replication topologies), and Advanced (covering B-Trees vs LSM-Trees, Gossip consensus protocols, consistent hashing rings, and distributed transaction Saga patterns).
Use Study Mode to build conceptual understanding question-by-question, or use Exam Mode to simulate GATE, university finals, or job interview conditions with full scoring and detailed explanations revealed upon submission.
Contents
- 1.Basics (20 Questions)core definitions Β· relational model Β· schema differences Β· standard databases Β· vertical/horizontal scaling
- 2.Concepts (20 Questions)CAP Theorem Β· ACID vs BASE Β· sharding patterns Β· document querying Β· replication topologies
- 3.Advanced (20 Questions)B-Trees vs LSM-Trees Β· Gossip consensus Β· consistent hashing Β· distributed transactions Saga
- 4.Conclusionsummary Β· next steps Β· study tips
- 5.Key Takeawaysquick-fire bullet recap of essential facts
- 6.Quick Review Summaryconcept Β· definition Β· key fact table
- 7.FAQcommon questions answered
SQL vs NoSQL Databases β Basics
1What does the acronym "SQL" stand for?
CorrectC: Structured Query Language
Exactly: Structured Query Language. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectC: Structured Query Language
Exactly: Structured Query Language. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
2Which data model is the foundational architecture for traditional SQL databases?
CorrectD: The Relational Model
Exactly: The Relational Model. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectD: The Relational Model
Exactly: The Relational Model. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
3What is the primary characteristic of a NoSQL database's schema?
CorrectC: It is typically dynamic or "schema-less", allowing flexible and varying data structures
Exactly: It is typically dynamic or "schema-less", allowing flexible and varying data structures. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectC: It is typically dynamic or "schema-less", allowing flexible and varying data structures
Exactly: It is typically dynamic or "schema-less", allowing flexible and varying data structures. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
4Which of the following is a classic, widely used SQL database management system?
CorrectA: PostgreSQL
Exactly: PostgreSQL. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: PostgreSQL
Exactly: PostgreSQL. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
5How do traditional SQL databases typically scale to handle increased load?
CorrectB: By upgrading the existing server with more CPU, RAM, and storage (Vertical Scaling)
Exactly: By upgrading the existing server with more CPU, RAM, and storage (Vertical Scaling). Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: By upgrading the existing server with more CPU, RAM, and storage (Vertical Scaling)
Exactly: By upgrading the existing server with more CPU, RAM, and storage (Vertical Scaling). Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
6Which of the following is a prominent example of a Document-oriented NoSQL database?
CorrectC: MongoDB
Exactly: MongoDB. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectC: MongoDB
Exactly: MongoDB. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
7In a relational SQL database, how is data fundamentally organized?
CorrectB: Into tables consisting of strictly defined rows and columns
Exactly: Into tables consisting of strictly defined rows and columns. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: Into tables consisting of strictly defined rows and columns
Exactly: Into tables consisting of strictly defined rows and columns. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
8What does the term "Horizontal Scaling" (Scale-out) mean in the context of NoSQL databases?
CorrectA: Adding more independent servers or nodes to distribute the data and traffic load
Exactly: Adding more independent servers or nodes to distribute the data and traffic load. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: Adding more independent servers or nodes to distribute the data and traffic load
Exactly: Adding more independent servers or nodes to distribute the data and traffic load. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
9Which scenario is typically a poor fit for a NoSQL document database?
CorrectD: Financial systems requiring absolute mathematical precision and complex, multi-table transactions
Exactly: Financial systems requiring absolute mathematical precision and complex, multi-table transactions. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectD: Financial systems requiring absolute mathematical precision and complex, multi-table transactions
Exactly: Financial systems requiring absolute mathematical precision and complex, multi-table transactions. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
10In SQL terminology, what serves as a unique identifier for a specific row within a table?
CorrectA: The Primary Key
Exactly: The Primary Key. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: The Primary Key
Exactly: The Primary Key. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
11Which of the following NoSQL categories is specifically designed to store highly connected data, such as social networks or recommendation engines?
CorrectC: Graph Databases
Exactly: Graph Databases. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectC: Graph Databases
Exactly: Graph Databases. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
12What language do NoSQL databases primarily use for querying data?
CorrectD: They use varying, database-specific query languages and APIs (e.g., MQL for MongoDB, Cypher for Neo4j)
Exactly: They use varying, database-specific query languages and APIs (e.g., MQL for MongoDB, Cypher for Neo4j). Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectD: They use varying, database-specific query languages and APIs (e.g., MQL for MongoDB, Cypher for Neo4j)
Exactly: They use varying, database-specific query languages and APIs (e.g., MQL for MongoDB, Cypher for Neo4j). Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
13What represents a "Foreign Key" in a relational SQL database?
CorrectB: A column in one table that references the primary key of another table to establish a relationship
Exactly: A column in one table that references the primary key of another table to establish a relationship. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: A column in one table that references the primary key of another table to establish a relationship
Exactly: A column in one table that references the primary key of another table to establish a relationship. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
14Which of the following data formats is most commonly associated with data retrieval and storage in Document NoSQL databases?
CorrectB: JSON (JavaScript Object Notation) or BSON
Exactly: JSON (JavaScript Object Notation) or BSON. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: JSON (JavaScript Object Notation) or BSON
Exactly: JSON (JavaScript Object Notation) or BSON. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
15Why might a development team choose a NoSQL database over a SQL database for a massive IoT (Internet of Things) sensor project?
CorrectA: Because NoSQL easily handles the extreme high-velocity, high-volume ingestion of unstructured sensor data
Exactly: Because NoSQL easily handles the extreme high-velocity, high-volume ingestion of unstructured sensor data. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: Because NoSQL easily handles the extreme high-velocity, high-volume ingestion of unstructured sensor data
Exactly: Because NoSQL easily handles the extreme high-velocity, high-volume ingestion of unstructured sensor data. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
16What is a "Key-Value Store"?
CorrectC: A highly simplistic NoSQL database where every item is stored as an attribute name (key) linked to its data payload (value)
Exactly: A highly simplistic NoSQL database where every item is stored as an attribute name (key) linked to its data payload (value). Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectC: A highly simplistic NoSQL database where every item is stored as an attribute name (key) linked to its data payload (value)
Exactly: A highly simplistic NoSQL database where every item is stored as an attribute name (key) linked to its data payload (value). Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
17Which principle ensures that a relational database transaction brings the database from one valid state to another?
CorrectA: Consistency
Exactly: Consistency. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: Consistency
Exactly: Consistency. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
18If a system requires deep, complex queries joining five different entities together, which database type is inherently optimized for this?
CorrectD: A Relational SQL Database
Exactly: A Relational SQL Database. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectD: A Relational SQL Database
Exactly: A Relational SQL Database. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
19How do SQL databases typically handle schema modifications (like adding a new mandatory field)?
CorrectB: The database structure must be formally altered via commands like 'ALTER TABLE', often requiring downtime or locking
Exactly: The database structure must be formally altered via commands like 'ALTER TABLE', often requiring downtime or locking. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: The database structure must be formally altered via commands like 'ALTER TABLE', often requiring downtime or locking
Exactly: The database structure must be formally altered via commands like 'ALTER TABLE', often requiring downtime or locking. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
20Which of the following databases operates primarily as an ultra-fast, in-memory Key-Value store?
CorrectA: Redis
Exactly: Redis. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: Redis
Exactly: Redis. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
SQL vs NoSQL Databases β Concepts
1What does the "ACID" acronym guarantee in traditional SQL database transactions?
CorrectC: Atomicity, Consistency, Isolation, Durability
Exactly: Atomicity, Consistency, Isolation, Durability. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectC: Atomicity, Consistency, Isolation, Durability
Exactly: Atomicity, Consistency, Isolation, Durability. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
2In contrast to ACID, many NoSQL databases operate on the "BASE" model. What does BASE stand for?
CorrectD: Basically Available, Soft state, Eventual consistency
Exactly: Basically Available, Soft state, Eventual consistency. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectD: Basically Available, Soft state, Eventual consistency
Exactly: Basically Available, Soft state, Eventual consistency. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
3According to the CAP Theorem, a distributed database system can provide at most two of which three guarantees simultaneously?
CorrectA: Consistency, Availability, Partition Tolerance
Exactly: Consistency, Availability, Partition Tolerance. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: Consistency, Availability, Partition Tolerance
Exactly: Consistency, Availability, Partition Tolerance. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
4In a distributed NoSQL environment facing a network partition, a system that chooses Availability over Consistency (AP) will exhibit what behavior?
CorrectB: It will continue serving requests from active nodes, but might return stale or outdated data to the client
Exactly: It will continue serving requests from active nodes, but might return stale or outdated data to the client. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: It will continue serving requests from active nodes, but might return stale or outdated data to the client
Exactly: It will continue serving requests from active nodes, but might return stale or outdated data to the client. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
5What is "Eventual Consistency" in a distributed NoSQL database?
CorrectC: A model where updates to a system will propagate across all nodes over time, ensuring all replicas eventually converge to the same value
Exactly: A model where updates to a system will propagate across all nodes over time, ensuring all replicas eventually converge to the same value. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectC: A model where updates to a system will propagate across all nodes over time, ensuring all replicas eventually converge to the same value
Exactly: A model where updates to a system will propagate across all nodes over time, ensuring all replicas eventually converge to the same value. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
6How does a Wide-Column Store (like Apache Cassandra) organize its data internally?
CorrectA: As multi-dimensional maps indexed by a row key, column name, and timestamp, allowing dynamic columns per row
Exactly: As multi-dimensional maps indexed by a row key, column name, and timestamp, allowing dynamic columns per row. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: As multi-dimensional maps indexed by a row key, column name, and timestamp, allowing dynamic columns per row
Exactly: As multi-dimensional maps indexed by a row key, column name, and timestamp, allowing dynamic columns per row. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
7Why is "Sharding" commonly associated with NoSQL databases?
CorrectB: It is a native horizontal scaling technique that partitions data across multiple independent servers based on a shard key
Exactly: It is a native horizontal scaling technique that partitions data across multiple independent servers based on a shard key. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: It is a native horizontal scaling technique that partitions data across multiple independent servers based on a shard key
Exactly: It is a native horizontal scaling technique that partitions data across multiple independent servers based on a shard key. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
8In relational databases, what does the process of "Normalization" achieve?
CorrectA: It organizes data to minimize redundancy and eliminate insertion, update, and deletion anomalies
Exactly: It organizes data to minimize redundancy and eliminate insertion, update, and deletion anomalies. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: It organizes data to minimize redundancy and eliminate insertion, update, and deletion anomalies
Exactly: It organizes data to minimize redundancy and eliminate insertion, update, and deletion anomalies. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
9Why do NoSQL developers often employ "Denormalization"?
CorrectD: To optimize read performance by duplicating data, thereby avoiding the heavy computational cost of joining data across networks
Exactly: To optimize read performance by duplicating data, thereby avoiding the heavy computational cost of joining data across networks. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectD: To optimize read performance by duplicating data, thereby avoiding the heavy computational cost of joining data across networks
Exactly: To optimize read performance by duplicating data, thereby avoiding the heavy computational cost of joining data across networks. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
10In a Graph database (like Neo4j), what represents the relationships connecting different data entities?
CorrectD: Edges
Exactly: Edges. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectD: Edges
Exactly: Edges. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
11What is the "Impedance Mismatch" problem often cited when using Object-Oriented programming languages with SQL databases?
CorrectB: The conceptual friction between representing data as interconnected objects in code versus flat, normalized tables in a relational database
Exactly: The conceptual friction between representing data as interconnected objects in code versus flat, normalized tables in a relational database. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: The conceptual friction between representing data as interconnected objects in code versus flat, normalized tables in a relational database
Exactly: The conceptual friction between representing data as interconnected objects in code versus flat, normalized tables in a relational database. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
12Which of the following is a fundamental limitation of implementing strict ACID transactions across a massive, globally distributed NoSQL cluster?
CorrectB: Ensuring absolute isolation and consistency across disparate nodes introduces severe latency, killing the horizontal scalability the cluster was built for
Exactly: Ensuring absolute isolation and consistency across disparate nodes introduces severe latency, killing the horizontal scalability the cluster was built for. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: Ensuring absolute isolation and consistency across disparate nodes introduces severe latency, killing the horizontal scalability the cluster was built for
Exactly: Ensuring absolute isolation and consistency across disparate nodes introduces severe latency, killing the horizontal scalability the cluster was built for. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
13If you need to store and rapidly query massive time-series data (like millions of server metrics per second), which database architecture is typically best suited?
CorrectB: A Wide-Column Store (e.g., Cassandra) or specialized Time-Series DB
Exactly: A Wide-Column Store (e.g., Cassandra) or specialized Time-Series DB. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: A Wide-Column Store (e.g., Cassandra) or specialized Time-Series DB
Exactly: A Wide-Column Store (e.g., Cassandra) or specialized Time-Series DB. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
14What is the primary function of a "Secondary Index" in a Document database like MongoDB?
CorrectA: To allow efficient querying of documents based on fields other than the primary document ID
Exactly: To allow efficient querying of documents based on fields other than the primary document ID. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: To allow efficient querying of documents based on fields other than the primary document ID
Exactly: To allow efficient querying of documents based on fields other than the primary document ID. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
15Which relational database feature automatically executes a specific block of SQL code when a predefined event (like an INSERT or UPDATE) occurs on a table?
CorrectC: A Database Trigger
Exactly: A Database Trigger. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectC: A Database Trigger
Exactly: A Database Trigger. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
16In the context of CAP theorem, traditional relational SQL databases (like Oracle or PostgreSQL) deployed on a single node fundamentally prioritize which two guarantees?
CorrectA: Consistency and Availability (CA)
Exactly: Consistency and Availability (CA). Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: Consistency and Availability (CA)
Exactly: Consistency and Availability (CA). Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
17What is "Polyglot Persistence" in modern software architecture?
CorrectC: The strategic use of multiple, different database technologies (both SQL and NoSQL) within the same system to handle different specific workloads optimally
Exactly: The strategic use of multiple, different database technologies (both SQL and NoSQL) within the same system to handle different specific workloads optimally. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectC: The strategic use of multiple, different database technologies (both SQL and NoSQL) within the same system to handle different specific workloads optimally
Exactly: The strategic use of multiple, different database technologies (both SQL and NoSQL) within the same system to handle different specific workloads optimally. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
18How do Document databases generally handle the lack of complex, cross-table JOIN operations?
CorrectA: By embedding related data directly within a single, hierarchical document
Exactly: By embedding related data directly within a single, hierarchical document. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: By embedding related data directly within a single, hierarchical document
Exactly: By embedding related data directly within a single, hierarchical document. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
19What does "Schema-on-Read" mean in the context of NoSQL databases?
CorrectB: Data is written without structural validation; structure and data types are only applied and interpreted by the application when the data is queried
Exactly: Data is written without structural validation; structure and data types are only applied and interpreted by the application when the data is queried. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: Data is written without structural validation; structure and data types are only applied and interpreted by the application when the data is queried
Exactly: Data is written without structural validation; structure and data types are only applied and interpreted by the application when the data is queried. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
20Which mechanism do SQL databases use to guarantee that a transaction either completely succeeds or completely fails, with no partial states?
CorrectC: The Atomicity property utilizing transaction logs
Exactly: The Atomicity property utilizing transaction logs. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectC: The Atomicity property utilizing transaction logs
Exactly: The Atomicity property utilizing transaction logs. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
SQL vs NoSQL Databases β Advanced
1In a horizontally partitioned NoSQL database, what is the primary danger of selecting an inappropriate "Shard Key"?
CorrectB: It can cause "Hotspotting," where one specific shard receives the vast majority of traffic, completely negating the performance benefits of horizontal scaling
Exactly: It can cause "Hotspotting," where one specific shard receives the vast majority of traffic, completely negating the performance benefits of horizontal scaling. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: It can cause "Hotspotting," where one specific shard receives the vast majority of traffic, completely negating the performance benefits of horizontal scaling
Exactly: It can cause "Hotspotting," where one specific shard receives the vast majority of traffic, completely negating the performance benefits of horizontal scaling. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
2How do modern relational databases (like PostgreSQL) execute complex multi-table joins under the hood?
CorrectC: By utilizing sophisticated algorithmic strategies like Nested Loop, Hash Join, and Merge Join
Exactly: By utilizing sophisticated algorithmic strategies like Nested Loop, Hash Join, and Merge Join. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectC: By utilizing sophisticated algorithmic strategies like Nested Loop, Hash Join, and Merge Join
Exactly: By utilizing sophisticated algorithmic strategies like Nested Loop, Hash Join, and Merge Join. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
3What underlying data structure do traditional relational SQL databases primarily use to maintain efficient index searches and range queries?
CorrectA: Balanced Trees (B-Trees or B+ Trees)
Exactly: Balanced Trees (B-Trees or B+ Trees). Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: Balanced Trees (B-Trees or B+ Trees)
Exactly: Balanced Trees (B-Trees or B+ Trees). Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
4Conversely, many highly write-optimized NoSQL databases (like Cassandra or RocksDB) utilize which core data structure to avoid the heavy mechanical write penalty of B-Trees?
CorrectB: Log-Structured Merge-Trees (LSM Trees) paired with MemTables and SSTables
Exactly: Log-Structured Merge-Trees (LSM Trees) paired with MemTables and SSTables. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: Log-Structured Merge-Trees (LSM Trees) paired with MemTables and SSTables
Exactly: Log-Structured Merge-Trees (LSM Trees) paired with MemTables and SSTables. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
5In a distributed NoSQL system utilizing the "Gossip Protocol," how is cluster state maintained?
CorrectA: Nodes periodically exchange state information with a few random peers, allowing cluster topology and health metrics to rapidly propagate across the entire network
Exactly: Nodes periodically exchange state information with a few random peers, allowing cluster topology and health metrics to rapidly propagate across the entire network. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: Nodes periodically exchange state information with a few random peers, allowing cluster topology and health metrics to rapidly propagate across the entire network
Exactly: Nodes periodically exchange state information with a few random peers, allowing cluster topology and health metrics to rapidly propagate across the entire network. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
6What is "Consistent Hashing" and why is it critical for scalable NoSQL Key-Value stores like Dynamo or Cassandra?
CorrectB: It is an algorithm that minimizes the reassignment of keys when nodes are added or removed, ensuring data is distributed evenly around a logical ring without massive reshuffling
Exactly: It is an algorithm that minimizes the reassignment of keys when nodes are added or removed, ensuring data is distributed evenly around a logical ring without massive reshuffling. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: It is an algorithm that minimizes the reassignment of keys when nodes are added or removed, ensuring data is distributed evenly around a logical ring without massive reshuffling
Exactly: It is an algorithm that minimizes the reassignment of keys when nodes are added or removed, ensuring data is distributed evenly around a logical ring without massive reshuffling. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
7In Graph databases, what is "Index-Free Adjacency"?
CorrectA: A physical storage architecture where every node maintains direct memory pointers to its connected neighboring nodes, allowing highly efficient, deep relationship traversal without relying on global indexes
Exactly: A physical storage architecture where every node maintains direct memory pointers to its connected neighboring nodes, allowing highly efficient, deep relationship traversal without relying on global indexes. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: A physical storage architecture where every node maintains direct memory pointers to its connected neighboring nodes, allowing highly efficient, deep relationship traversal without relying on global indexes
Exactly: A physical storage architecture where every node maintains direct memory pointers to its connected neighboring nodes, allowing highly efficient, deep relationship traversal without relying on global indexes. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
8When a relational SQL database experiences a "Deadlock," what has occurred?
CorrectA: Two or more concurrent transactions are mutually waiting for locks held by each other, bringing execution to a permanent halt
Exactly: Two or more concurrent transactions are mutually waiting for locks held by each other, bringing execution to a permanent halt. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: Two or more concurrent transactions are mutually waiting for locks held by each other, bringing execution to a permanent halt
Exactly: Two or more concurrent transactions are mutually waiting for locks held by each other, bringing execution to a permanent halt. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
9In Cassandra (a Wide-Column NoSQL store), what is the function of the "Commit Log"?
CorrectA: It serves as a durable, append-only disk log to guarantee crash recovery and durability before data is written to the in-memory MemTable
Exactly: It serves as a durable, append-only disk log to guarantee crash recovery and durability before data is written to the in-memory MemTable. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: It serves as a durable, append-only disk log to guarantee crash recovery and durability before data is written to the in-memory MemTable
Exactly: It serves as a durable, append-only disk log to guarantee crash recovery and durability before data is written to the in-memory MemTable. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
10How do distributed SQL engines (like Google Spanner or CockroachDB) achieve strong consistency and ACID guarantees across global geographic distances?
CorrectA: By utilizing synchronized atomic clocks (TrueTime) or complex consensus protocols (like Raft or Paxos) to serialize distributed transactions accurately
Exactly: By utilizing synchronized atomic clocks (TrueTime) or complex consensus protocols (like Raft or Paxos) to serialize distributed transactions accurately. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: By utilizing synchronized atomic clocks (TrueTime) or complex consensus protocols (like Raft or Paxos) to serialize distributed transactions accurately
Exactly: By utilizing synchronized atomic clocks (TrueTime) or complex consensus protocols (like Raft or Paxos) to serialize distributed transactions accurately. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
11What is "Multi-Version Concurrency Control" (MVCC) in relational databases?
CorrectD: A method of managing concurrent access by keeping multiple timestamped versions of data, allowing readers to view a consistent snapshot without blocking writers
Exactly: A method of managing concurrent access by keeping multiple timestamped versions of data, allowing readers to view a consistent snapshot without blocking writers. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectD: A method of managing concurrent access by keeping multiple timestamped versions of data, allowing readers to view a consistent snapshot without blocking writers
Exactly: A method of managing concurrent access by keeping multiple timestamped versions of data, allowing readers to view a consistent snapshot without blocking writers. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
12In the context of MongoDB (a Document NoSQL database), how does an "Aggregation Pipeline" function?
CorrectA: A framework that processes data records through a multi-stage process (like match, group, project) where each stage transforms the documents as they pass through
Exactly: A framework that processes data records through a multi-stage process (like match, group, project) where each stage transforms the documents as they pass through. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: A framework that processes data records through a multi-stage process (like match, group, project) where each stage transforms the documents as they pass through
Exactly: A framework that processes data records through a multi-stage process (like match, group, project) where each stage transforms the documents as they pass through. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
13What is the "Two-Phase Commit" (2PC) protocol used for in distributed database systems?
CorrectB: To ensure atomic transaction commit across multiple independent database nodes, coordinating a "prepare" phase followed by a global "commit" or "rollback" phase
Exactly: To ensure atomic transaction commit across multiple independent database nodes, coordinating a "prepare" phase followed by a global "commit" or "rollback" phase. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: To ensure atomic transaction commit across multiple independent database nodes, coordinating a "prepare" phase followed by a global "commit" or "rollback" phase
Exactly: To ensure atomic transaction commit across multiple independent database nodes, coordinating a "prepare" phase followed by a global "commit" or "rollback" phase. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
14Why is the concept of a "Tombstone" critical in LSM-Tree based NoSQL databases (like Cassandra)?
CorrectB: Because data is strictly appended, a tombstone is a special marker written to explicitly indicate a record has been deleted, suppressing the older data during subsequent reads until compaction occurs
Exactly: Because data is strictly appended, a tombstone is a special marker written to explicitly indicate a record has been deleted, suppressing the older data during subsequent reads until compaction occurs. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: Because data is strictly appended, a tombstone is a special marker written to explicitly indicate a record has been deleted, suppressing the older data during subsequent reads until compaction occurs
Exactly: Because data is strictly appended, a tombstone is a special marker written to explicitly indicate a record has been deleted, suppressing the older data during subsequent reads until compaction occurs. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
15In relational database tuning, what is the primary consequence of extreme "Over-Indexing"?
CorrectB: While read speeds might improve, write/update/delete operations suffer massive performance degradation because every index must be synchronously updated alongside the base data
Exactly: While read speeds might improve, write/update/delete operations suffer massive performance degradation because every index must be synchronously updated alongside the base data. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectB: While read speeds might improve, write/update/delete operations suffer massive performance degradation because every index must be synchronously updated alongside the base data
Exactly: While read speeds might improve, write/update/delete operations suffer massive performance degradation because every index must be synchronously updated alongside the base data. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
16Which of the following best describes "Vector Clocks" in a distributed NoSQL system (like Amazon Dynamo)?
CorrectD: A mathematical mechanism used to capture causality and detect concurrent update conflicts across multiple distributed replicas without requiring centralized timestamps
Exactly: A mathematical mechanism used to capture causality and detect concurrent update conflicts across multiple distributed replicas without requiring centralized timestamps. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectD: A mathematical mechanism used to capture causality and detect concurrent update conflicts across multiple distributed replicas without requiring centralized timestamps
Exactly: A mathematical mechanism used to capture causality and detect concurrent update conflicts across multiple distributed replicas without requiring centralized timestamps. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
17In a strictly normalized SQL database, what is the primary difference between Third Normal Form (3NF) and Boyce-Codd Normal Form (BCNF)?
CorrectA: BCNF is a stricter version of 3NF that drops the exception allowing functional dependencies where the dependent attribute is a prime attribute
Exactly: BCNF is a stricter version of 3NF that drops the exception allowing functional dependencies where the dependent attribute is a prime attribute. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: BCNF is a stricter version of 3NF that drops the exception allowing functional dependencies where the dependent attribute is a prime attribute
Exactly: BCNF is a stricter version of 3NF that drops the exception allowing functional dependencies where the dependent attribute is a prime attribute. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
18How does "Read Repair" function in an eventually consistent NoSQL database?
CorrectC: When a client reads data from multiple replicas and detects a version mismatch, the coordinator node automatically issues a background write to update the stale replicas with the most recent data
Exactly: When a client reads data from multiple replicas and detects a version mismatch, the coordinator node automatically issues a background write to update the stale replicas with the most recent data. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectC: When a client reads data from multiple replicas and detects a version mismatch, the coordinator node automatically issues a background write to update the stale replicas with the most recent data
Exactly: When a client reads data from multiple replicas and detects a version mismatch, the coordinator node automatically issues a background write to update the stale replicas with the most recent data. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
19In the context of database replication, what is the primary disadvantage of "Synchronous Replication" compared to "Asynchronous Replication"?
CorrectA: Synchronous replication severely impacts write latency, as the master node must wait for confirmation from replica nodes before acknowledging the commit to the client
Exactly: Synchronous replication severely impacts write latency, as the master node must wait for confirmation from replica nodes before acknowledging the commit to the client. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectA: Synchronous replication severely impacts write latency, as the master node must wait for confirmation from replica nodes before acknowledging the commit to the client
Exactly: Synchronous replication severely impacts write latency, as the master node must wait for confirmation from replica nodes before acknowledging the commit to the client. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
20What does the "Saga Pattern" solve in modern microservice and distributed polyglot persistence architectures?
CorrectC: It manages distributed transactions across multiple independent databases without using distributed locking (like 2PC), utilizing a sequence of local transactions and compensating actions for rollbacks
Exactly: It manages distributed transactions across multiple independent databases without using distributed locking (like 2PC), utilizing a sequence of local transactions and compensating actions for rollbacks. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
IncorrectC: It manages distributed transactions across multiple independent databases without using distributed locking (like 2PC), utilizing a sequence of local transactions and compensating actions for rollbacks
Exactly: It manages distributed transactions across multiple independent databases without using distributed locking (like 2PC), utilizing a sequence of local transactions and compensating actions for rollbacks. Refer to fundamental SQL vs NoSQL architecture principles for deeper technical context.
Conclusion: Mastering SQL vs NoSQL Databases
These 60 MCQs cover the complete SQL vs NoSQL spectrum β from understanding relational schema constraints and database categories, to analyzing consistency guarantees under the CAP Theorem and ACID vs BASE models, to designing sharded systems and high-throughput write path architectures.
The key mental model: SQL excels in highly structured, transaction-heavy systems requiring strict ACID consistency, while NoSQL offers horizontal scalability and flexible schema-on-read for distributed, high-velocity data environments. Choosing the right database is always a matter of balancing your read/write paths, consistency needs, and operational scaling costs.
After completing this practice set, deepen your engineering design skills with the full SQL vs NoSQL Databases theory notes and explore real-world system designs like polyglot persistence and microservices saga patterns.
π Key Takeaways β SQL vs NoSQL
- SQL: Relational model, tables, rows/columns, rigid schemas, highly structured.
- NoSQL: Document, Key-Value, Graph, Wide-Column stores. Flexible schema on read.
- ACID: Atomicity, Consistency, Isolation, Durability (Guarantees strict correctness).
- BASE: Basically Available, Soft state, Eventual consistency (Guarantees high performance).
- CAP Theorem: Pick two out of three: Consistency, Availability, Partition Tolerance.
- Scaling: SQL traditionally scales vertically. NoSQL inherently scales horizontally.
- B-Trees: Used extensively in SQL databases for rapid read indexes.
- LSM-Trees: Used extensively in NoSQL databases for massive write throughput.
Quick Review & Summary
| Concept | SQL Approach | NoSQL Approach |
|---|---|---|
| Data Model | Relational Tables (Rows/Cols) | Document, KV, Graph, Column |
| Schemas | Strict schema-on-write | Dynamic schema-on-read |
| Scaling | Vertical Scaling (Scale-up) | Horizontal Scaling (Scale-out) |
| Transactions | ACID guarantees | BASE models (Eventual consistency) |
| Joins | Complex native JOIN parsing | Denormalization / App-side joining |
| Data structures | B-Trees generally used | LSM-Trees often used for heavy writes |
| Examples | MySQL, PostgreSQL, Oracle | MongoDB, Cassandra, Redis, Neo4j |
Frequently Asked Questions
Q. How many SQL vs NoSQL MCQs are available on this page?
Q. What specific topics do these MCQs cover?
Q. Are these MCQs suitable for System Design interview prep?
Q. What is the difference between ACID and BASE consistency models?
Q. When should you choose NoSQL over SQL for a project?
Q. What is the CAP theorem and why does it matter for database selection?
Struggling with some questions? Re-read the full Theory Guide: SQL vs NoSQL Databases