Top 50 Data Analyst Interview Questions 2026 โ€” SQL, Python, Case Studies (With Answers)
๐Ÿ“Š Data Analyst

Top 50 Data Analyst Interview Questions 2026 โ€” With Answers

Real SQL, Python, case study and behavioural questions asked at Google, Amazon, Flipkart, Swiggy, Paytm and 30+ top companies in 2026. Complete answers, difficulty ratings, and the companies that ask each question.

By Prakhar Shrivastavaยท April 24, 2026ยท12 min readยทUpdated weekly
Quick Answer
Data analyst interviews in 2026 have 3โ€“4 rounds: SQL technical test, Python/take-home assignment, business case study, and behavioural round. The most tested SQL topics are window functions (92%), JOINs (89%) and GROUP BY (85%). Python means Pandas โ€” specifically groupby, merge and data cleaning.

SQL Interview Questions โ€” Data Analyst 2026

Definition: SQL (Structured Query Language) is used to query and manage data in relational databases. It is the #1 required skill for data analysts โ€” tested in 95%+ of interviews.

๐Ÿ†
Most Tested: Window FunctionsWindow functions perform calculations across related rows without collapsing them like GROUP BY. RANK(), ROW_NUMBER(), LAG(), LEAD() and SUM() OVER() are tested in 92% of senior data analyst interviews.

Easy SQL Questions

#QuestionTopicAsked At
1Write a query to find all customers from Mumbai with orders over โ‚น5,000WHERE + JOINInfosys, TCS
2Find duplicate emails in a customer tableGROUP BY + HAVINGWipro, Accenture
3Get the top 5 products by revenueORDER BY + LIMITMeesho, CRED
4Find all employees earning above the company average salarySubqueryAmazon, Paytm
5Count total orders and revenue per product categoryGROUP BY + AggregatesFlipkart, Swiggy
๐Ÿ’ก
AEO Block โ€” SQL Quick AnswerQ: What is the difference between WHERE and HAVING?
WHERE filters individual rows before grouping. HAVING filters groups after GROUP BY runs. Use WHERE to filter raw data, HAVING to filter aggregated results. Example: WHERE salary > 50000 filters rows; HAVING COUNT(*) > 5 filters groups.

Medium SQL Questions

#QuestionTopicAsked At
6For each department, find the employee with the highest salaryWindow Functions: ROW_NUMBER()Amazon, Razorpay
7Find customers who ordered in Jan 2024 but NOT in Feb 2024NOT IN / Anti-JOINFlipkart, Swiggy
8Calculate month-over-month revenue growth %LAG() window functionZomato, PhonePe
9Find the percentage each category contributes to total revenueSUM OVER() / PARTITIONWalmart, EY
10Find each manager and the count of their direct reportsSelf JOINInfosys, Accenture
11Calculate cumulative revenue by date (running total)SUM OVER ORDER BYMeesho, CRED
12Find the top 3 customers per city by revenueROW_NUMBER + PARTITIONGoogle, Amazon

Hard SQL Questions

SQL โ€” Classic Hard Question: Consecutive Days
— Find users active on 3+ consecutive days in last 30 days
WITH daily AS (
SELECT DISTINCT user_id, DATE(activity_date) dt
FROM user_activity
WHERE activity_date >= CURRENT_DATE30
),
grouped AS (
SELECT user_id, dt,
dt – ROW_NUMBER() OVER(PARTITION BY user_id ORDER BY dt) AS grp
FROM daily
)
SELECT DISTINCT user_id
FROM grouped
GROUP BY user_id, grp
HAVING COUNT(*) >= 3;

Full SQL practice: SQL Interview Hub with Live Compiler โ†’

Python (Pandas) Interview Questions โ€” 2026

Definition: Pandas is a Python library for data manipulation and analysis. It provides DataFrame objects for structured data operations. Pandas is tested in 75% of data analyst interviews at product companies.

#QuestionPandas FunctionDifficulty
13Find top 5 products by revenue using groupbygroupby + agg + sort_valuesEasy
14Merge two DataFrames and find average order value per citymerge() + groupbyMedium
15Clean a DataFrame with missing values โ€” explain and implement strategydropna, fillna, isnullMedium
16Write a function to detect outliers using IQRNumPy + PandasMedium-Hard
17Create a pivot table: revenue by region and product categorypivot_table()Medium
18Apply a custom function to transform a columnapply() + lambdaEasy
19Calculate 7-day rolling average of daily active usersrolling() + mean()Hard
20Find users who churned (last purchase > 90 days ago)pd.to_datetime + date arithmeticMedium

Business Case Study Questions

Case study rounds are asked at Google, Amazon, Flipkart, Swiggy, Zomato, and all major product companies. Three frameworks cover 90% of all case study questions:

1

Metric Drop Framework

Q: ‘DAU dropped 20% last Tuesday โ€” how do you investigate?’ โ†’ Step 1: Clarify (what metrics, what time period, which platform?) โ†’ Step 2: Segment (by region, device, feature, user cohort) โ†’ Step 3: Hypothesise (external event? product change? data pipeline issue?) โ†’ Step 4: Validate โ†’ Step 5: Recommend fix

2

Metric Design Framework

Q: ‘How would you measure success of the new checkout feature?’ โ†’ Step 1: Define goal (increase conversion) โ†’ Step 2: Leading KPIs (checkout start rate, step completion rates) โ†’ Step 3: Lagging KPIs (GMV, revenue per user) โ†’ Step 4: Guardrail metrics (returns, cancellations) โ†’ Step 5: Dashboard structure

3

A/B Test Design Framework

Q: ‘Design an experiment to test if the new onboarding improves 30-day retention’ โ†’ Step 1: Hypothesis (new onboarding increases 30-day retention by 5%) โ†’ Step 2: Unit of randomisation (user_id) โ†’ Step 3: Sample size calculation โ†’ Step 4: Duration (โ‰ฅ1 full week, ideally 2 weeks) โ†’ Step 5: Success metrics + guardrail metrics โ†’ Step 6: Analysis plan

โš ๏ธ
Case Study Interview TipAlways clarify before jumping to analysis. Ask: ‘Has anything changed in the product recently?’ and ‘Is this metric drop seen across all platforms or specific ones?’ Showing structured thinking matters more than getting to the right answer quickly.

Behavioural Questions for Data Analyst Roles

  • “Tell me about a time you used data to change a decision that was already made”
  • “Describe a situation where your analysis was wrong โ€” what did you do?”
  • “How have you communicated complex data insights to a non-technical audience?”
  • “Tell me about a project where you had to work with incomplete or messy data”
  • “Describe a time you influenced a product decision with your analysis”

Answer all using the STAR method: STAR Method Complete Guide โ†’

โ“ Frequently Asked Questions
What SQL topics are most tested in data analyst interviews in 2026?
+
The most tested SQL topics in order of frequency: Window functions โ€” RANK, ROW_NUMBER, LAG, LEAD (92% of senior interviews), SQL JOINs โ€” all types especially anti-join pattern (89%), GROUP BY + HAVING with aggregations (85%), CTEs and subqueries (78%), Date functions and string manipulation (62%).
Do data analyst interviews test machine learning?
+
Entry-level data analyst interviews rarely test ML. Mid-level roles may ask about A/B testing, statistical significance, and correlation vs causation. Only senior analyst or data scientist hybrid roles test ML algorithms. Focus on SQL, Python Pandas, and business case studies for most analyst roles.
What Python libraries should I know for data analyst interviews?
+
Essential: Pandas (groupby, merge, pivot_table, apply, data cleaning) and NumPy (arrays, statistical functions). Good to know: Matplotlib and Seaborn (data visualization). Optional: Scikit-learn (for data science leaning roles). Pandas is by far the most tested โ€” master it completely before moving to other libraries.
How long is a data analyst interview process?
+
Typical data analyst interview process: 1โ€“2 weeks total. Week 1: Online SQL/Python screening test or take-home assignment (24โ€“48 hours). Week 2: 2โ€“3 rounds of video interviews (technical + case study + behavioral). Some companies compress this to 1 week. FAANG companies (Google, Amazon) take 2โ€“4 weeks.
What salary can I expect as a data analyst in India in 2026?
+
Data analyst salaries in India 2026: Fresher (0โ€“2 years): โ‚น4โ€“8 LPA. Mid-level (2โ€“5 years): โ‚น8โ€“18 LPA at product companies, โ‚น6โ€“12 LPA at IT services. Senior (5+ years): โ‚น18โ€“35 LPA at top startups and MNCs. Python + SQL + ML skills command 30โ€“40% premium. See our full guide: Python Salary in India 2026.

โญ Key Takeaways

  • SQL is tested in 95% of data analyst interviews โ€” window functions are the hardest and most tested topic
  • Python means Pandas: groupby, merge, pivot_table, apply, data cleaning are the core topics
  • Three case study frameworks cover 90% of questions: metric drop, metric design, A/B testing
  • Behavioural questions โ€” prepare 5 achievement stories using STAR method
  • Always clarify before solving a case study โ€” structured thinking > speed
  • Full free practice available: SQL Hub with live compiler and Python Hub with 20 pages

Practice these questions with a real mentor

Book a free data analyst mock interview. We run through SQL, Python and case study rounds with live feedback.

Book Free Mock Session