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.

Tuesday, June 9, 2026

Top Tableau Scenario-Based Interview Questions Set - 26 (1- 10)

 

1. How would you calculate the difference between current month's sales and the average sales of the last 3 months?

Use a moving average and subtract it from current sales.

SUM([Sales]) -
WINDOW_AVG(SUM([Sales]),-2,0)

2. How would you identify customers whose total sales exceed ₹1,00,000?

Create a conditional flag.

IF { FIXED [Customer ID] : SUM([Sales]) } > 100000
THEN "High Value"
ELSE "Normal"
END

3. How would you find the first order amount for each customer?

Use FIXED LOD to get the first order date.

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

4. How would you calculate month-over-month profit growth %?

Compare current month profit with previous month.

(
SUM([Profit]) -
LOOKUP(SUM([Profit]),-1)
)
/
ABS(LOOKUP(SUM([Profit]),-1))

5. How would you identify products that generated more than ₹50,000 profit?

Create a flag using FIXED LOD.

IF { FIXED [Product Name] : SUM([Profit]) } > 50000
THEN "Top Product"
END

6. How would you calculate average sales per order?

Divide sales by distinct order count.

SUM([Sales])
/
COUNTD([Order ID])

7. How would you identify customers whose latest order was placed this month?

Compare latest order month with current month.

DATETRUNC('month',
{ FIXED [Customer ID] : MAX([Order Date]) }
)
=
DATETRUNC('month',TODAY())

8. How would you calculate cumulative profit percentage?

Divide running profit by total profit.

RUNNING_SUM(SUM([Profit]))
/
TOTAL(SUM([Profit]))

9. How would you identify the top customer within each region?

Rank customer sales by region.

RANK(SUM([Sales])) = 1

Compute Using: Customer Name
Partition By: Region


10. How would you calculate the average monthly sales for each customer?

Calculate total sales per customer divided by active months.

{ FIXED [Customer ID] : SUM([Sales]) }
/
{ FIXED [Customer ID] :
COUNTD(DATETRUNC('month',[Order Date]))
}

This gives the average sales generated by a customer per active month.