1 Reply Latest reply on Feb 12, 2019 1:12 PM by Paul Wachtler

    Calculated Conditional Measure not displaying proper sum?

    Metin Erman

      I have a worksheet with a calculated measure that sums the number of cases from 2 different data sources(open cases and closed cases) and returns a value for each employee when the case has an age of 0(ie, was created today), but this doesn't seem to be returning the proper values in all cases.

      The Closed Cases Data Source is the base data source and the Open Cases data source is linked by:

      • Created By -> Query Created By
      • Report Date -> Report Date

      Calculated Measure is (Measure is on the pending case):

      SUM(IF [Closed Cases].[Age] < 1 THEN 1 ELSE 0 END) + SUM(IF Age < 1 THEN 1 ELSE 0 END) 

      This seems like it should be pretty clear what I am going to ge back, but it is not working properly. I look at the last 2 days for each employee(report date is the column). I have an employee with 14 cases created in the resolved cases with an age of 0 but it is not showing any for 2/11, but on 2/8 it is showing 7, which is the correct number. I am not sure how it can work fine for one day but not for the other on the same report. Also as a test I created a new worksheet and created a new measure on the closed cases with this exact same formula and it gave me a completely different number(way higher number in the hundreds for most employees).

      What am I doing wrong and how can I get it to show the correct number? I cannot filter by Age because I have other columns on the sheet that are not filtered by age, so I need this conditional calulated measure to work properly...

      Unfortunately I cannot attach a workbook because it is confidential data.