These are SQL questions of the kind Tech Mahindra actually asks — the patterns that keep coming back in Tech Mahindra's online tests and technical interview rounds for freshers. My advice: treat this page as a mock test. Attempt every question on paper first, then reveal. If any answer surprises you, the lesson it comes from is linked right below — go read it, then come back.
Tech Mahindra SQL concept questions
What is the difference between DBMS and RDBMS?
Asked in
Tech Mahindra SQL query questions
Using the same employees table, write a query to list employees who do not currently have a manager assigned (i.e., their manager_id is NULL).
Asked in


employees9 rows
| emp_id | name | department | salary | manager_id | join_date | |
|---|---|---|---|---|---|---|
| 1 | Alice Sharma | Engineering | 95000 | NULL | 2019-03-12 | alice.sharma@corp.com |
| 2 | Bob Iyer | Engineering | 72000 | 1 | 2020-07-01 | bob.iyer@corp.com |
| 3 | Chitra Rao | Sales | 65000 | NULL | 2018-11-20 | chitra.rao@corp.com |
| 4 | David Paul | Sales | 58000 | 3 | 2021-01-15 | david.paul@gmail.com |
| 5 | Esha Nair | Engineering | 88000 | 1 | 2019-09-05 | esha.nair@corp.com |
| 6 | Farhan Khan | Marketing | 60000 | NULL | 2020-02-28 | farhan.khan@corp.com |
| 7 | Gita Menon | Marketing | 60000 | 6 | 2022-04-10 | gita.menon@gmail.com |
| 8 | Harish Verma | Sales | NULL | 3 | 2022-06-18 | harish.verma@corp.com |
| 9 | Amit Verma | Sales | 52000 | 3 | 2021-08-01 | amit.verma@corp.com |
Given batch_2025(student_id) and placement_drive(student_id), write a query to fetch the records common to both tables — without using INTERSECT (older MySQL doesn't support it).
Asked in
batch_20254 rows
| student_id |
|---|
| 1 |
| 2 |
| 3 |
| 4 |
placement_drive3 rows
| student_id |
|---|
| 2 |
| 4 |
| 5 |
How to use this page: Tech Mahindra rarely asks a question you've never seen — they ask standard patterns with a twist. Master the pattern in the SQL course lessons, and the twist stops mattering.
Keep practising: SQL Basics, Joins, GROUP BY & HAVING and Subqueries cover what most Tech Mahindra SQL rounds test — and the Tech Mahindra exam guide covers the rest of their selection process.

