⚡ TechVani: AI, Technology, Apps, Coding & Digital World
TechVaniAI • Technology • Apps • Coding • Digital World
HomeAI & TechAppsCodingFree AI ToolsStudent TechSecurityAboutContactPrivacy
TECHVANI // LEARN. BUILD. TEST.

Learn the tech. Build the idea.

Clear study notes, tested lab files and practical guides for coding, AI and digital safety.

Explore Latest →
šŸ¤– AI & TechAI news, tools & guides šŸ“± Apps & ToolsUseful apps & websites šŸ’» CodingProgramming & web development šŸŽ“ Student TechStudy & career technology šŸ” Cyber SecuritySafety & awareness

Latest Posts

Circuit Notebook theme

Exam Notes

šŸ“š BTech CSE Exam Notes

Find Semester 1-8 subjects in one place. Choose a semester and open the notes you need. This is a general study guide, not an official syllabus.

Open Exam Notes →🧪 Open Lab Files →

Exam Numericals & Study Series

Practice CPU scheduling and explore OS and DBMS topics in separate, easy-to-follow parts. New topics will appear in the hub as they are published.

Open Numericals Hub →

Start here and stay in touch

New to TechVani? Start with our free AI tools guide for students. It covers which tools to try and what to check before relying on an answer.

For step-by-step videos, visit SiteSudhar on YouTube.

Join TechVani on WhatsApp

Get new AI tools and coding guides in your WhatsApp Updates tab.

Browse Topics

Popular Posts

TechVani

DBMS Important Questions Unit Wise with Answers

One free practice sheet for the whole DBMS exam: the questions worth practising from every unit, marked by answer length (1M, 4M, 6M), with every long answer one click away in the matching TechVani notes.

This sheet collects expected-style practice questions for a typical BTech Database Management Systems course, organized unit by unit to match our nine-part DBMS notes. The marks tags tell you how long the answer should be: 1M one sentence, 4M four short points, 6M a fuller answer with a diagram or worked example. One-mark answers are given inline; longer answers live in the linked notes so this page stays a clean checklist.

How to use it: pick one unit, answer every question on paper without opening the notes, then check yourself against the linked worked answers. Two honest notes: this is original practice material built from our own notes, not a leaked or predicted paper, and no sheet can guarantee marks - it tells you exactly what to practise.

Unit 1: Relational Model and Keys (DBMS Part 1)

  1. 1M Define a primary key. Answer: a minimal set of attributes whose values uniquely identify each row in a table, and which cannot be NULL.
  2. 1M What is a foreign key? Answer: an attribute (or set) in one table that references the primary key of another table, enforcing referential integrity.
  3. 1M State one difference between a candidate key and a primary key. Answer: a table can have many candidate keys; the primary key is the one chosen among them to identify rows.
  4. 4M Explain super key, candidate key, primary key and alternate key with one example table.
  5. 4M What is referential integrity? Show with an example what happens on DELETE and UPDATE of a referenced row.
  6. 6M Design a small two-table schema (Students, Enrollments) and explain every constraint you would declare and why.
  7. 6M Given a relation and a set of attributes, find all candidate keys using attribute closure. Practice set: 6 solved candidate-key problems.

Full worked answers: Unit 1: Relational Model and Keys notes.

Unit 2: ER Model (DBMS Part 2)

  1. 1M What is an entity set? Answer: a collection of similar entities that share the same attributes, such as all Students.
  2. 1M Define cardinality in an ER relationship. Answer: the number of entities of one set that can be associated with an entity of the other set, such as one-to-many.
  3. 4M Explain weak entity sets with an example, and how they are identified using a partial key plus the owner key.
  4. 4M Differentiate one-to-one, one-to-many and many-to-many relationships with one real example each.
  5. 6M Draw an ER diagram for a library (Members, Books, Loans) and map it to tables, marking all cardinalities.
  6. 6M Explain total vs partial participation with an example, and show how each changes the resulting table design.

Full worked answers: Unit 2: ER Model notes.

Unit 3: SQL: JOINs, GROUP BY, HAVING (DBMS Part 3)

  1. 1M What does GROUP BY do? Answer: it collects rows that share the same values in the grouped columns into one summary row per group.
  2. 1M Where vs HAVING in one line. Answer: WHERE filters rows before grouping; HAVING filters groups after aggregation.
  3. 4M Write and explain a query joining two tables and aggregating with COUNT and GROUP BY, line by line.
  4. 4M Explain LEFT JOIN vs INNER JOIN with a two-table example where one row has no match.
  5. 6M Given an Employees and Departments schema, write three queries: join with aggregation, HAVING filter, and a NULL-safe count. Predict each output.
  6. 6M Solve and explain the classic NULL traps: COUNT(*) vs COUNT(column), and NULL in comparisons.

Full worked answers: Unit 3: SQL: JOINs, GROUP BY, HAVING notes.

Unit 4: Relational Algebra (DBMS Part 4)

  1. 1M Name the basic relational algebra operators. Answer: selection, projection, union, set difference, Cartesian product and rename.
  2. 1M What does the selection operator do? Answer: it picks the rows of a relation that satisfy a condition, keeping all columns.
  3. 4M Explain selection, projection and Cartesian product with a small two-table worked example.
  4. 4M Show how an INNER JOIN can be written using Cartesian product plus selection, with an example.
  5. 6M For a given Student-Course-Enrollment schema, write relational algebra expressions for four queries and show the resulting tables.
  6. 6M Explain set operations (union, intersection, difference) in relational algebra, including the union-compatibility rule.

Full worked answers: Unit 4: Relational Algebra notes.

Unit 5: Normalization (DBMS Part 5)

  1. 1M What is normalization? Answer: the process of structuring tables to reduce redundancy and avoid update anomalies, using normal forms.
  2. 1M State the rule for 1NF. Answer: every attribute holds only atomic (indivisible) values, with no repeating groups.
  3. 4M Explain 1NF, 2NF and 3NF, each with a small table that violates it and the fixed design.
  4. 4M What is a partial dependency and how does removing it produce 2NF? Show with an example.
  5. 6M Given a relation and its functional dependencies, normalize it step by step to 3NF, justifying each decomposition.
  6. 6M Explain BCNF vs 3NF: when does a 3NF relation still violate BCNF? Give a concrete example.

Full worked answers: Unit 5: Normalization notes.

Unit 6: Transactions and ACID (DBMS Part 6)

  1. 1M What is a transaction? Answer: a logical unit of work, a sequence of operations treated as one indivisible action against the database.
  2. 1M Expand ACID. Answer: Atomicity, Consistency, Isolation, Durability.
  3. 4M Explain each ACID property with the bank-transfer example.
  4. 4M Describe the transaction states (active, partially committed, committed, failed, aborted) with a state diagram.
  5. 6M Explain COMMIT, ROLLBACK and SAVEPOINT with a worked SQL example, including what happens on failure.
  6. 6M What problems appear when transactions run without control? Explain dirty read, lost update and unrepeatable read with small timelines.

Full worked answers: Unit 6: Transactions and ACID notes.

Unit 7: Concurrency Control and 2PL (DBMS Part 7)

  1. 1M What is a serial schedule? Answer: a schedule in which transactions run one after another with no interleaving.
  2. 1M Define conflict serializability. Answer: a schedule is conflict serializable if its conflicting operations can be reordered into an equivalent serial schedule.
  3. 4M Test a given schedule for conflict serializability using a precedence graph, step by step.
  4. 4M Explain shared and exclusive locks and their compatibility table.
  5. 6M Explain two-phase locking (growing and shrinking phases), show a schedule that follows it, and prove why it guarantees serializability.
  6. 6M What is a deadlock? Show a two-transaction deadlock timeline and explain detection and recovery.

Full worked answers: Unit 7: Concurrency Control and 2PL notes.

Unit 8: Crash Recovery (DBMS Part 8)

  1. 1M What is write-ahead logging? Answer: the rule that a log record describing a change must be written to stable storage before the changed data page is written.
  2. 1M What is a checkpoint? Answer: a marker that periodically forces dirty pages and log to disk so recovery starts from a known recent point.
  3. 4M Explain the role of the log in recovery: undo and redo, with a short crash timeline.
  4. 4M Compare immediate vs deferred database modification with an example of each.
  5. 6M Walk through recovery after a crash: which transactions are undone and which redone, given a sample log with a checkpoint.
  6. 6M Explain shadow paging as an alternative to log-based recovery, with its advantages and costs.

Full worked answers: Unit 8: Crash Recovery notes.

Unit 9: Indexing and B+ Trees (DBMS Part 9)

  1. 1M What is an index? Answer: a data structure that speeds up row lookup on the indexed attributes, at the cost of extra storage and slower writes.
  2. 1M Primary vs secondary index in one line. Answer: a primary index is on the ordered key field of the file; a secondary index is on any other field.
  3. 4M Explain the structure of a B+ tree (root, internal nodes, linked leaves) and why databases prefer it over a binary search tree.
  4. 4M Dense vs sparse index: definitions, one diagram each, and when each is possible.
  5. 6M Insert a given key sequence into an order-3 B+ tree step by step, drawing the tree after each split.
  6. 6M Explain clustered vs non-clustered indexes and how the choice affects query plans, with a worked SELECT example.

Full worked answers: Unit 9: Indexing and B+ Trees notes.

Keep practising

Comments