# DBMS Concepts

> Cover keys, ER models, normalisation, transactions and ACID, concurrency control and indexing at interview depth. Free notes, key concepts, resources and a...

Canonical: https://www.internhack.in/roadmaps/tracks/dsa-placement/dbms
Last updated: 2026-11-28

Cover keys, ER models, normalisation, transactions and ACID, concurrency control and indexing at interview depth.

Intermediate · about 8 hours · difficulty 3/5

Learn first: [How Campus and Off-Campus Hiring Works](https://www.internhack.in/roadmaps/tracks/dsa-placement/placement-landscape)

DBMS questions appear in nearly every technical interview for freshers. Interviewers want clear definitions plus one example each.

### Core concepts

- **Keys**: super, candidate, primary, alternate, foreign and composite keys.
- **ER model**: entities, attributes, relationships, cardinality (1:1, 1:N, M:N) and converting ER diagrams to tables.
- **Normalisation**: 1NF, 2NF, 3NF and BCNF, with functional dependencies; explain the anomalies (insert, update, delete) each one removes. Know when denormalisation helps reads.
- **Transactions and ACID**: atomicity, consistency, isolation, durability with a bank transfer example.
- **Concurrency**: dirty read, non-repeatable read, phantom read; isolation levels; locking and two-phase locking; deadlocks in databases.
- **Indexing**: why B+ trees, clustered vs non-clustered indexes, when an index is not used.
- SQL vs NoSQL at a high level, and the CAP theorem in one paragraph.

### Pitfalls

- Defining 2NF and 3NF without a concrete example table.
- Saying "indexes make everything faster" without mentioning write cost and storage.

You are ready to move on when you can normalise a messy student-course table to 3NF on a whiteboard and explain ACID with a money transfer.

## Key concepts

- **Types of keys**
- **ER model to tables**
- **Functional dependencies**
- **Normal forms: 1NF to BCNF**
- **Transactions and ACID**
- **Isolation levels and anomalies**
- **Indexing and B+ trees**
- **SQL vs NoSQL and CAP**

## Mini project

Design a college placement database (students, companies, drives, applications, offers): draw the ER diagram, convert it to tables in 3NF, mark all keys, and write a one-page note on which columns you would index and why.

## Check yourself

Explain a non-repeatable read with a two-transaction example, and which isolation level prevents it.

## Free resources

- [Database System Concepts (Silberschatz) companion site](https://www.db-book.com/) (db-book.com)
- [Use The Index, Luke](https://use-the-index-luke.com/) (Markus Winand)
- [GeeksforGeeks](https://www.geeksforgeeks.org/) (GeeksforGeeks)

Previous: [Object-Oriented Programming](https://www.internhack.in/roadmaps/tracks/dsa-placement/oop) · Next: [SQL for Interviews and OAs](https://www.internhack.in/roadmaps/tracks/dsa-placement/sql-interviews)

## More in CS Core Subjects for Interviews

- [Object-Oriented Programming](https://www.internhack.in/roadmaps/tracks/dsa-placement/oop)
- [DBMS Concepts](https://www.internhack.in/roadmaps/tracks/dsa-placement/dbms)
- [SQL for Interviews and OAs](https://www.internhack.in/roadmaps/tracks/dsa-placement/sql-interviews)
- [Operating Systems](https://www.internhack.in/roadmaps/tracks/dsa-placement/operating-systems)
- [Computer Networks](https://www.internhack.in/roadmaps/tracks/dsa-placement/computer-networks)

## Related

- [Roadmaps](https://www.internhack.in/roadmaps)
- [DSA and Placement Prep Roadmap](https://www.internhack.in/roadmaps/tracks/dsa-placement)
