Quick Revision

GK One-Line Question & Answer

15541+ short questions with short answers, covering every category and sub-category on the site — no long articles to scroll through. Good for a fast recap before an exam, or a few minutes of daily practice.

DBMS → Normalization 9

BCNF is preferred over 3NF when
Eliminating ALL FD-based redundancy is the priority (some FDs can be lost)
click to copy
Denormalization is performed to
Improve query performance by intentionally adding some redundancy
click to copy
When relation has only one candidate key, 3NF and BCNF are
Equivalent (same set of qualifying relations)
click to copy
Practical normalization typically stops at
3NF or BCNF (balance between redundancy and performance)
click to copy
BCNF violation: R(A,B,C) with AB→C and C→B. C→B violates BCNF because
C+ = {C,B} ≠ {A,B,C} so C is NOT a superkey
click to copy
Moving from 2NF to 3NF removes
Transitive dependencies
click to copy
2NF ensures non-key attributes depend on
The ENTIRE primary key
click to copy
DKNF (Domain-Key Normal Form) is
Theoretical NF where every constraint follows from domain and key constraints
click to copy
Fix for EmpID→DeptID→DeptName (3NF violation) is
Create Dept(DeptID,DeptName) and Emp(EmpID,DeptID)
click to copy

DBMS → Introduction to DBMS 23

Multi-valued dependency A→→B means
For each A value, B values independent of all other attributes
click to copy
Extraneous attribute in FD can be removed without
Changing the overall closure implied by FD set F
click to copy
Non-loss decomposition is another term for
Lossless-join decomposition
click to copy
A relation with single-attribute PK is automatically in
2NF (no partial dependencies possible without composite key)
click to copy
Pseudotransitivity rule: if X→Y and WY→Z then
WX→Z
click to copy
StudentName depends on StudentID in PK(StudentID,CourseID). This is what violation?
2NF - partial dependency
click to copy
A relation with ONLY one attribute is always in
BCNF
click to copy
Isolation ensures
Concurrent transactions do not interfere with each other
click to copy
Dirty read occurs when
T1 reads data written by uncommitted T2 (invalid if T2 rolls back)
click to copy
Non-repeatable read occurs when
Same row read twice gives different values because another transaction modified it between reads
click to copy
Phantom read occurs when
New rows APPEAR in repeated range query inserted by another transaction
click to copy
2PL growing phase
Only acquires locks (no releasing allowed)
click to copy
2PL shrinking phase
Only releases locks (no new acquisitions allowed)
click to copy
2PL guarantees
Conflict serializability
click to copy
Strict 2PL holds exclusive locks until
Transaction COMMITS or ABORTS
click to copy
Two operations conflict when
Same data item, different transactions, at least one is a WRITE
click to copy
Wait-Die scheme: T_i requests lock held by T_j
Older T_i waits; younger T_i aborts (dies)
click to copy
Wound-Wait scheme: T_i requests lock held by T_j
Older T_i wounds (aborts) T_j; younger T_i waits
click to copy
MVCC keeps multiple versions to
Allow readers and writers to proceed without blocking each other
click to copy
READ UNCOMMITTED isolation
Allows ALL anomalies (dirty, non-repeatable, phantom) - lowest isolation, highest concurrency
click to copy
READ COMMITTED isolation
Prevents dirty reads but allows non-repeatable and phantom reads
click to copy
REPEATABLE READ isolation
Prevents dirty and non-repeatable reads but may allow phantom reads
click to copy
Shared (S) lock allows
Multiple concurrent readers no writers
click to copy

DBMS → Transactions 4

ACID stands for
Atomicity,Consistency,Isolation,Durability
click to copy
Atomicity ensures
Transaction happens in entirety or not at all
click to copy
Consistency ensures
DB transitions from one valid state to another maintaining all integrity constraints
click to copy
Durability ensures
Once committed changes persist permanently even after system failures
click to copy

DBMS → Concurrency Control 2

A schedule is conflict serializable if
Its precedence graph is ACYCLIC (no cycles)
click to copy
SERIALIZABLE isolation
Prevents ALL anomalies - highest isolation, lowest concurrency
click to copy

DBMS → Deadlock 2

Deadlock occurs when
Two or more transactions wait indefinitely for each other to release locks (circular wait)
click to copy
Wait-for graph detects deadlock when
A CYCLE is detected in the graph
click to copy