0% found this document useful (0 votes)
101 views

Scenario - Based Power BI Interview Q&A-1

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
101 views

Scenario - Based Power BI Interview Q&A-1

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 9

Scenario - Based Power BI Interview Q&A

1. Data Relationship

Question:
Given a dataset with 'Customer Age' and 'Purchase Amount,' how would you
visualize their relationship? Which graph would you use and why?

Answer:
Use a scatter plot with 'Customer Age' on the x-axis and 'Purchase Amount' on the
y-axis to identify correlations or trends. Adding a trendline helps visualize the
pattern. If there are categories like 'Customer Segment,' use different colors or
markers to highlight variations.

2. Measure vs. Calculated Column

Question:
In Power BI, when would you prefer a measure over a calculated column? Provide
an example.

Answer:

● Use a measure for dynamic, context-sensitive calculations, e.g., calculating


total sales for a specific date range.
● Use a calculated column for row-level calculations that remain static, e.g.,
creating a 'Profit Margin' column as (Profit / Sales) * 100.

Example: A measure is preferred to calculate year-to-date (YTD) sales


dynamically:

YTD Sales = TOTALYTD(SUM(Sales[SalesAmount]), Dates[Date])


3. Correlation Analysis

Question:
For a dataset containing monthly sales and marketing spend, which graph would
best illustrate their correlation? Why?

Answer:
A scatter plot with a trendline is ideal to visualize correlation. It shows the
relationship between sales and marketing spend. Additionally, if you want to
observe changes over time, overlay the correlation on a line chart with dual axes.

4. Hierarchical Filtering

Question:
How would you implement a hierarchical filter for Region → Country → City in
Power BI?

Answer:

1. Create a hierarchy in the data model with 'Region,' 'Country,' and 'City.'
2. Add a slicer for the hierarchy, enabling users to drill down.
3. Use visuals like tables or matrixes to display data that respects the
hierarchy.

5. Interactive Region Filter

Question:
How would you allow users to filter sales data interactively by region and product
category?

Answer:

1. Add slicers for 'Region' and 'Product Category' to the dashboard.


2. Ensure relationships in the model allow proper filtering.
3. Optionally, use drillthrough pages to allow users to view region-specific
sales details.

6. Dynamic Reporting

Question:
How would you allow users to toggle between different metrics (e.g., Sales, Profit,
and Expenses) in a single chart?

Answer:

1. Create a parameter table listing the metrics.


2. Add a slicer for the parameter.
3. Use a DAX measure to switch between metrics:

SelectedMetric =

SWITCH(
SELECTEDVALUE(Metrics[Metric]),
"Sales", SUM(Sales[Amount]),
"Profit", SUM(Sales[Profit]),
"Expenses", SUM(Sales[Expense])
)

4. Use this measure in the chart.

7. Performance Optimization

Question:
How would you ensure a Power BI report with millions of rows remains
performant?

Answer:

● Aggregate data at the source.


● Use Direct Query or Hybrid Models for large datasets.
● Avoid heavy calculated columns; prefer measures instead.
● Optimize relationships by ensuring appropriate cardinality (e.g.,
many-to-one).
● Use Visual Level Filters to reduce the number of data points in charts.

8. KPI Visualization

Question:
How would you display KPIs such as Total Revenue and Profit Margin in Power
BI?

Answer:
Use card visuals for static metrics like Total Revenue. For dynamic KPIs with
thresholds, use KPI visuals that compare current values against targets. Optionally,
use gauges for progress visualization.

9. Real-Time Dashboard

Question:
How can you create a Power BI dashboard that tracks real-time order statuses?

Answer:

1. Connect to a streaming dataset using Azure Stream Analytics or APIs.


2. Design visuals like cards for KPIs and line charts for order trends.
3. Enable data refresh intervals for live updates.

10. Null Handling

Question:
How would you handle null or missing values in Power BI?
Answer:

1. Use the IF DAX function to replace nulls:

Revenue = IF(ISBLANK(Sales[Revenue]), 0, Sales[Revenue])


2. Apply a filter to exclude null values in the visual.
3. Highlight rows with missing values by creating flags using DAX.

11. Time-Series Analysis

Question:
How would you visualize sales trends and forecast future values?

Answer:

1. Use a line chart to visualize historical trends.


2. Enable Analytics in the visual to add a trendline or forecast.
3. Use DAX for custom date-based calculations like YTD or MTD sales:

YTD Sales = TOTALYTD(SUM(Sales[Amount]), Dates[Date])

12. Row-Level Security

Question:
How would you restrict data access so users only see their respective region’s
sales?

Answer:

1. Define roles in Power BI Desktop using DAX:

[Region] = USERPRINCIPALNAME()
2. Assign users to roles in the Power BI Service.
3. Test roles with the 'View as Role' feature.
13. Conditional Formatting

Question:
How would you highlight products with low profitability in Power BI?

Answer:

1. Create a DAX measure for profitability:

Profitability = SUM(Sales[Profit]) / SUM(Sales[Revenue])


2. Use conditional formatting in a table visual to apply a red color for rows
where profitability is below 10%.

14. Advanced Drillthrough

Question:
How would you implement drillthrough functionality to analyze specific customer
segments?

Answer:

1. Create a drillthrough page with visuals focusing on customer details.


2. Add fields like 'Customer Segment' to the Drillthrough Filters section.
3. Users can right-click a segment in the main report and navigate to the
drillthrough page.

15. Complex Data Transformation

Question:
How would you clean and transform messy data with duplicate rows and
inconsistent formats in Power BI?

Answer:
1. Use Power Query to:
○ Remove duplicates.
○ Standardize text formats using transformations like Trim, Uppercase,
etc.
○ Handle missing values with default replacements.
2. Load the cleaned dataset into the model for analysis.

16. Custom Date Filters

Question:
How would you create a filter to show sales data for the last 7 days dynamically?

Answer:
Create a calculated column:

Last7Days =
IF(
Dates[Date] >= TODAY() - 7 && Dates[Date] <= TODAY(),
"Last 7 Days",
"Other"
)

Use this column as a slicer for filtering.

17. Comparing Target vs. Actual

Question:
How would you visualize variance between target and actual sales?

Answer:

1. Use a clustered bar chart with separate bars for actual and target values.
2. Add a DAX measure for variance:

Variance = SUM(Sales[Actual]) - SUM(Sales[Target])


3. Use conditional formatting to highlight positive and negative variances.

18. Real-Time Alerts

Question:
How would you set up alerts for KPI breaches in Power BI?

Answer:

1. Create a card visual for the KPI.


2. Publish the report to Power BI Service.
3. Set up data alerts to notify users when thresholds are breached (e.g., profit
margin < 10%).

19. Advanced Metrics

Question:
How would you calculate and visualize a weighted average in Power BI?

Answer:
Create a DAX measure:

WeightedAvg = SUMX(Table, Table[Value] * Table[Weight]) /


SUM(Table[Weight])

Use this measure in a card or chart visual to display the weighted average.

20. Address Matching


Question:
How would you match customer addresses with slight variations (e.g.,
abbreviations) in Power BI?

Answer:

1. Use Power Query to clean the data by removing special characters and
standardizing formats.
2. If variations persist, use Python or R scripts within Power BI to apply fuzzy
matching.

You might also like