TGViewer
Data Analyst Interview Resources Data Analyst Interview Resources @dataanalystinterview · 52.5K subscribers
Post #776 1.89K
Some Imp Scenario Q & A for product based Company :
You are a data analyst at a logistics company. The company wants to analyze delivery performance and customer satisfaction. Your tasks are:
1. Identify late deliveries and their impact on customer satisfaction.
2. Calculate the average delivery time for each region.
3. Create a Power BI report to visualize delivery performance and identify areas for improvement

Answer:

SQL Queries to Retrieve Data
1. Identify Late Deliveries and Their Impact on Customer Satisfaction:
SELECT
d.DeliveryID,
d.CustomerID,
d.DeliveryDate,
d.ExpectedDeliveryDate,
d.DeliveryTime,
c.SatisfactionScore
FROM Deliveries d
JOIN Customers c ON d.CustomerID = c.CustomerID
WHERE d.DeliveryDate > d.ExpectedDeliveryDate;

2. Calculate the Average Delivery Time for Each Region:
SELECT
Region,
AVG(DATEDIFF(day, OrderDate, DeliveryDate)) AS AvgDeliveryTime
FROM Deliveries
GROUP BY Region;

3. Customer Satisfaction by Delivery Performance:
SELECT
DeliveryPerformance,
AVG(SatisfactionScore) AS AvgSatisfactionScore
FROM (
SELECT
d.CustomerID,
c.SatisfactionScore,
CASE
WHEN d.DeliveryDate <= d.ExpectedDeliveryDate THEN 'On Time'
ELSE 'Late'
END AS DeliveryPerformance
FROM Deliveries d
JOIN Customers c ON d.CustomerID = c.CustomerID
) AS DeliveryData
GROUP BY DeliveryPerformance;

Import Data into Power BI
1. Load Data:
Open Power BI Desktop.
Use the "Get Data" feature to connect to your SQL database.
Import the result sets from the SQL queries into Power BI.

2. Create Relationships (if necessary):
Ensure that the data tables are properly related, such as linking the Deliveries table to the Customers table.

Create Visualizations
1. Late Deliveries and Their Impact on Customer Satisfaction:
Create a table visual.
Drag DeliveryID, CustomerID, DeliveryDate, ExpectedDeliveryDate, DeliveryTime, and SatisfactionScore to the Values.

2. Average Delivery Time for Each Region:
Create a bar chart.
Drag Region to the Axis.
Drag AvgDeliveryTime to the Values.

3. Customer Satisfaction by Delivery Performance:
Create a bar chart.
Drag DeliveryPerformance to the Axis.
Drag AvgSatisfactionScore to the Values.

4. Overall Delivery Analysis:
Create a pie chart.
Drag Region to the Legend.
Drag AvgDeliveryTime to the Values.

Optimize Performance
1. Data Model Optimization:
Filter data to include only necessary columns and rows.
Use summarized tables to pre-aggregate data.

2. DAX Optimization:
Create measures for dynamic calculations.
Simplify DAX formulas to improve performance.

3. Visualization Optimization:
Limit the number of visuals per page.
Avoid excessive use of slicers or custom visuals that can impact performance.

I have curated best 80+ top-notch Data Analytics Resources 👇👇
https://whatsapp.com/channel/0029VaGgzAk72WTmQFERKh02

Like if it helps :)
  • 🥰 2
More from @dataanalystinterview
  1. Oct 16, 2026𝗗𝗮𝘁𝗮 𝘀𝗰𝗶𝗲𝗻𝗰𝗲 𝗖𝗲𝗿𝘁𝗶𝗳𝗶𝗰𝗮𝘁𝗶𝗼𝗻 𝗪𝗶𝘁𝗵 𝗔𝗜😍 Future Ready Data Scien…
  2. Oct 13, 2026✅ Complete Roadmap to Learn SQL (Structured Query Language) 🧠💻 Week 1: SQL Basics - What…
  3. Oct 13, 2026𝗧𝗢𝗣 𝗙𝗥𝗘𝗘 𝗖𝗢𝗨𝗥𝗦𝗘𝗦 𝗧𝗢 𝗕𝗢𝗢𝗦𝗧 𝗬𝗢𝗨𝗥 𝗦𝗞𝗜𝗟𝗟𝗦 𝗜𝗡 𝟮𝟬𝟮𝟲! Explor…
  4. Oct 12, 2026🚀 𝗪𝗵𝗶𝗰𝗵 𝗧𝗲𝗰𝗵 𝗦𝗸𝗶𝗹𝗹 𝗪𝗶𝗹𝗹 𝗬𝗼𝘂 𝗠𝗮𝘀𝘁𝗲𝗿 𝗶𝗻 𝟮𝟬𝟮𝟲? Want to buil…
  5. Oct 9, 2026✅SQL Roadmap: Step-by-Step Guide to Master SQL 🧠💻 Whether you're aiming to be a backend…
  6. Oct 9, 2026🇮🇳 𝗚𝗢𝗩𝗘𝗥𝗡𝗠𝗘𝗡𝗧 𝗢𝗙 𝗜𝗡𝗗𝗜𝗔 — 𝗔𝗜𝗖𝗧𝗘 𝗜𝗡𝗧𝗘𝗥𝗡𝗦𝗛𝗜𝗣𝗦 𝟮𝟬𝟮𝟲 🚀…
Threads Profile ViewerView any public Threads profile without an account.Open ThreadLook →Writing with AI? Make it sound human.Metric37 rewrites AI drafts so they read naturally. Free AI detector, 1,500 words free.Try Metric37 →