1 Reply Latest reply on Jun 13, 2016 4:22 PM by Tom W

    Level of Detail Expression - Error with dimension hierarchy

    Evan Anderson



      I am making a Tableau workbook for a consumer products client that I will eventually hand off to them. We conducted a survey of shoppers; I will be displaying each survey question result in an individual worksheet, with the percentage of respondents that answered each option, split by respondents' demographic information or product categories. Note that because this is a survey we are using weighted numbers for each respondent instead of simply counting who answered what. When the survey respondents begin the survey, they are told to answer questions in regards to a specific product category (e.g. women's clothing).


      I have created Level of Detail expressions that calculate the dynamic denominator for the survey respondents by their demographic information (shown below).


      {Fixed [Question ID],[Data Slicer]: SUM([Weight])}


      Here, the data slicer is the demographic information parameter.


      I want to create a similar Level of Detail expression that will calculate the denominator for respondents by the product category they spoke to, as well (i.e., the total weight of everyone who answered questions about women's clothing). My attempt is below:


      { FIXED [Question ID],[Sub-Categories]:SUM([Weight])}


      Here is the complication: The survey respondents are split into product categories that I have grouped into higher-level categories (e.g. clothing, which contains men's clothing, women's clothing, and children's clothing) . When I use the Level of Detail expression to calculate the denominator with the actual specific category survey respondents were grouped into, the calculation works. However, the level of detail expression does not work when I roll the categories up into a higher-level category (using the manual grouping I created).


      Has anyone encountered this issue before? Any and all help is much appreciated! Note that I cannot attach the results due to confidentiality concerns.