Friday, June 12, 2026

Top Tableau Scenario-Based Interview Questions Set -28 (1- 7)

 

1. How would you identify the customer who contributed the highest profit in each region?

Use Rank on Profit and partition by Region.

RANK(SUM([Profit])) = 1

Compute Using: Customer Name
Partition By: Region

This returns the top profit-generating customer in every region.


2. How would you calculate the average number of days taken to ship an order?

Calculate the difference between Order Date and Ship Date.

AVG(
DATEDIFF(
'day',
[Order Date],
[Ship Date]
))

This measures shipping efficiency.


3. How would you identify products that have sales in every month of the year?

Count distinct sales months and compare with 12.

{ FIXED [Product Name] :
COUNTD(DATETRUNC('month',[Order Date]))
} = 12

This identifies consistently selling products.


4. How would you calculate each customer's share of profit within their region?

Divide customer profit by total regional profit.

SUM([Profit])
/
WINDOW_SUM(SUM([Profit]))

Set Compute Using: Customer Name.

This shows profit contribution within a region.


5. How would you identify orders where discount is given but profit is negative?

Filter orders having discount and loss.

[Discount] > 0
AND
[Profit] < 0

Useful for identifying poor discounting strategies.


6. How would you calculate the average revenue generated per active month?

Divide total sales by distinct active months.

SUM([Sales])
/
COUNTD(
DATETRUNC('month',[Order Date])
)

This gives average monthly revenue.


7. How would you identify customers whose latest purchase amount is higher than their average purchase amount?

Compare latest order sales with customer average sales.

IF [Order Date] =
{ FIXED [Customer ID] : MAX([Order Date]) }
THEN [Sales]
END

Compare it against:

{ FIXED [Customer ID] : AVG([Sales]) }

This identifies customers whose recent spending is above their historical average.

Wednesday, June 10, 2026

Top Tableau Scenario-Based Interview Questions Set -27 (1- 5)

 

1. How would you identify customers who generated profit in every year?

Count the number of years with positive profit and compare it with total years.

{ FIXED [Customer ID] :
COUNTD(
IF [Profit] > 0
THEN YEAR([Order Date])
END
)
}
=
{ FIXED : COUNTD(YEAR([Order Date])) }

This returns customers who were profitable every year.


2. How would you calculate the percentage change between current sales and average sales?

Compare current sales against overall average sales.

(
SUM([Sales])
-
WINDOW_AVG(SUM([Sales]))
)
/
WINDOW_AVG(SUM([Sales]))

This shows how much a value is above or below the average.


3. How would you identify the customer with the highest single order value?

Compare each order against the maximum order amount.

SUM([Sales])
=
WINDOW_MAX(SUM([Sales]))

This returns the order/customer with the highest order value.


4. How would you calculate the ratio of profit to quantity sold?

Measure profit earned per unit sold.

SUM([Profit])
/
SUM([Quantity])

Useful for analyzing product efficiency and profitability.


5. How would you identify products whose sales are greater than the average sales of their category?

Compare product sales with category-level average using FIXED LOD.

SUM([Sales])
>
{ FIXED [Category] : AVG([Sales]) }

This highlights products outperforming their category average.