Central Exam — Computer Knowledge — Database/SQL
UPSC · SSC · Bank · Railway · NDA — Central Government Exam MCQ Practice
100 Questions 5 Topics Take Test
Advertisement
Showing 21–30 of 100 questions in Database/SQL
Q.21 Easy Database/SQL
What does ACID stand for in database transactions?
A Atomicity, Consistency, Isolation, Durability
B Availability, Consistency, Integrity, Distribution
C Atomicity, Concurrency, Isolation, Data
D Authorization, Consistency, Integration, Durability
Correct Answer:  A. Atomicity, Consistency, Isolation, Durability
Explanation:

ACID properties ensure reliable database transactions: Atomicity (all-or-nothing), Consistency (valid state), Isolation (concurrent independence), and Durability (permanent storage).

Take Test
Q.22 Easy Database/SQL
In SQL, which JOIN returns only matching records from both tables?
A INNER JOIN
B LEFT JOIN
C FULL OUTER JOIN
D CROSS JOIN
Correct Answer:  A. INNER JOIN
Explanation:

INNER JOIN returns only rows with matching values in both tables. LEFT JOIN includes unmatched left table rows, FULL OUTER JOIN includes all rows, and CROSS JOIN produces Cartesian product.

Take Test
Q.23 Medium Database/SQL
Which data structure is best suited for implementing a LRU (Least Recently Used) cache?
A Hash Map + Doubly Linked List
B Single Array
C Binary Search Tree
D Queue only
Correct Answer:  A. Hash Map + Doubly Linked List
Explanation:

LRU cache requires O(1) access and O(1) removal/insertion of least-used items. Hash Map provides O(1) lookup, and Doubly Linked List maintains order efficiently.

Take Test
Q.24 Easy Database/SQL
What is the time complexity of searching in a balanced binary search tree?
A O(log n)
B O(n)
C O(n log n)
D O(1)
Correct Answer:  A. O(log n)
Explanation:

Balanced BSTs (AVL, Red-Black) maintain O(log n) search time by keeping height logarithmic. Unbalanced trees degrade to O(n) in worst case.

Take Test
Q.25 Easy Database/SQL
In cloud computing, what does IaaS stand for?
A Infrastructure as a Service
B Integration as a Service
C Intelligent as a Service
D Internal as a Service
Correct Answer:  A. Infrastructure as a Service
Explanation:

IaaS provides virtualized computing resources over the internet (AWS EC2, Azure VMs). PaaS and SaaS are higher-level abstractions.

Take Test
Advertisement
Q.26 Medium Database/SQL
Which normalization form eliminates transitive dependencies?
A Third Normal Form (3NF)
B Second Normal Form (2NF)
C First Normal Form (1NF)
D Boyce-Codd Normal Form (BCNF)
Correct Answer:  A. Third Normal Form (3NF)
Explanation:

3NF removes transitive dependencies where non-key attributes depend on other non-key attributes. BCNF is stricter but 3NF eliminates transitive dependencies.

Take Test
Q.27 Medium Database/SQL
What is the primary purpose of database replication in distributed systems?
A Improve availability and fault tolerance
B Increase query processing speed only
C Reduce storage costs
D Eliminate the need for backups
Correct Answer:  A. Improve availability and fault tolerance
Explanation:

Replication maintains copies across nodes for high availability, disaster recovery, and load distribution. It doesn't eliminate backups—they serve different purposes.

Take Test
Q.28 Easy Database/SQL
In cybersecurity, what is the primary purpose of a firewall?
A Control incoming and outgoing network traffic based on rules
B Encrypt all data transmitted
C Detect viruses and malware
D Manage user authentication
Correct Answer:  A. Control incoming and outgoing network traffic based on rules
Explanation:

Firewalls filter traffic based on security policies. While they provide protection, encryption is separate, antivirus is different, and authentication is handled by other systems.

Take Test
Q.29 Medium Database/SQL
Which algorithm is commonly used for sorting in most programming language standard libraries?
A Introsort (Quicksort + Heapsort hybrid)
B Bubble Sort
C Insertion Sort
D Selection Sort
Correct Answer:  A. Introsort (Quicksort + Heapsort hybrid)
Explanation:

Modern languages use Introsort which starts with Quicksort (O(n log n) avg) but switches to Heapsort (O(n log n) worst) to avoid worst-case scenarios.

Take Test
Q.30 Hard Database/SQL
What does CAP theorem state in distributed systems?
A A system can guarantee at most 2 of 3: Consistency, Availability, Partition tolerance
B All distributed systems must be Consistent, Available, and Partition-tolerant
C Consistency requires Availability and Partitions
D Availability is always achieved in partitioned systems
Correct Answer:  A. A system can guarantee at most 2 of 3: Consistency, Availability, Partition tolerance
Explanation:

CAP theorem (Brewer's theorem) states distributed systems must choose 2 of 3 properties: strong consistency (C), continuous availability (A), or tolerance to network partitions (P).

Take Test
IGET
iget AI
Online · Ask anything about exams
Hi! 👋 I'm your iget AI assistant.

Ask me anything about exam prep, MCQ solutions, study tips, or strategies! 🎯
UPSC strategy SSC CGL syllabus Improve aptitude NEET Biology tips