pbPassingBI
/

What is LOD expression in Tableau?

advanced
Answer

A level of detail expression computes an aggregate at a granularity other than the view's, which is otherwise impossible because a calculation normally inherits the level of detail from whatever is on the shelves.

There are three types:

  • FIXED uses only the dimensions you name and ignores what is in the view. `{FIXED [Customer ID] : SUM([Sales])}` gives total sales per customer regardless of how the view is broken down. - INCLUDE uses the view's dimensions *plus* the ones you name, letting you compute more finely and then re-aggregate. - EXCLUDE uses the view's dimensions *minus* the ones you name, which is how you hold a total constant while the view breaks down beneath it.

The classic uses are customer lifetime value, cohort labelling, percent of total against a fixed denominator, and de-duplicating a measure that a join has fanned out.

The detail interviewers probe: FIXED is evaluated before view-level dimension filters take effect, so a quick filter appears not to affect it. Promoting that filter to context moves it earlier in the order of operations and fixes the behaviour.

Related questions