Skip to main content
Jyothi S ha fatto una domanda in K-12 Education

Hi,

I have one row for each combination of dim1, dim2 and dim3 that has multiple values of measure credit_amt which gives incorrect results for sum(credit_amt). I have various custom queries involved in data source

 

for eg:

 

dim1 dim2, dim3 credit_amt

 

A    X    P   10, 20, 30

 

I have used LOD, i.e. {fixed dim1, dim2, dim3 : sum(credit_amt)}, it is also giving incorrect results. Please assist me in this regard

1 risposta
  1. 25 ago 2025, 17:12

    Hi Jyothi,

     

    Thanks for sharing your question. Results from LODs are often understood by "reading" the LOD from back to front. For example, in the LOD you shared, it will return "the Sum of <credit_amt> for each dim1, dim2, dim3." I don't know what the results you are looking for are, but it may be you are looking for the MAX of an individual dimension. It may be that you need may want to use IF statement before or inside of your LOD to return a certain term in a dimension, example IF <dem1> = "Course A" THEN . . .

     

    It may be that you don't need and LOD at all.

     

    An LOD defines the level of detail (aka granularity) the calculation should be performed independently of the level of detail of the view. Granularity of your dimension suggests that you are looking at data that has logical levels or sub-groups such as district, building, grade level, classroom, student.

     

    Types of LOD Expressions:

    ● FIXED: compute a value using specified dimensions, without reference to the dimensions in the view

    ● INCLUDE: compute values using specified dimensions in addition to whatever dimensions are in the view

    ● EXCLUDE: declare dimensions to omit from the view level of detail

     

    Tableau Tim is a very nice man and explains things well on YouTube. Here is his LOD video https://www.youtube.com/watch?v=5ntCaHCsqUc. He can explain Tableau things better than me.