BigData / Tableau Interview Questions
What is a Level of Detail (LOD) expression?
An LOD expression lets you compute an aggregation at a level of detail that's different from the granularity of the view itself — something neither a normal calculated field nor a table calculation can do on their own.
{ FIXED [Customer ID] : SUM([Sales]) } { INCLUDE [Order ID] : SUM([Profit]) } { EXCLUDE [Sub-Category] : AVG([Discount]) }
- FIXED: computes the aggregation at exactly the dimensions listed, ignoring whatever's in the view.
- INCLUDE: computes at a finer level than the view by adding extra dimensions, useful inside calculations that need row-level detail temporarily.
- EXCLUDE: computes at a coarser level than the view by removing dimensions the view would otherwise use.
A classic example is "total sales per customer, shown alongside order-level rows" — a normal SUM([Sales]) would just repeat the order's own value, but { FIXED [Customer ID] : SUM([Sales]) } computes the true customer-level total and repeats that same total across every one of that customer's orders, regardless of how granular the view is.
Invest now in Acorns!!! 🚀
Join Acorns and get your $5 bonus!
Acorns is a micro-investing app that automatically invests your "spare change" from daily purchases into diversified, expert-built portfolios of ETFs. It is designed for beginners, allowing you to start investing with as little as $5. The service automates saving and investing. Disclosure: I may receive a referral bonus.
Invest now!!! Get Free equity stock (US, UK only)!
Use Robinhood app to invest in stocks. It is safe and secure. Use the Referral link to claim your free stock when you sign up!.
The Robinhood app makes it easy to trade stocks, crypto and more.
Webull! Receive free stock by signing up using the link: Webull signup.
More Related questions...
