7 Replies Latest reply: Aug 2, 2012 4:46 AM by rkapadia16 RSS

    Sum field by another distinct field

    bryankoch

      Hello,

      I'm trying to write an expression along the lines of

      sum the [Number of Rejections] for every distinct [Claim ID]. The data is pivoted so you'll see something along the lines of

       

       

      Claim IDCPTTime FrameNumber of RejectionsNumber of Denials
      110
      T120
      110T220
      112T120
      112T220
      112T320
      112T420
      113T121
      250T10
      2
      250T20
      2
      250T302
      251T100
      251T200
      251T300
      252T100
      340T111
      340T211
      340T311

      Where the number of rejections is Claim specific and the number of denials is cpt specific.

      For this example, I'm looking to get a sum of the total number of rejections, which should be 3 (2 for claim 1, 0 for claim 2, and 1 for claim 3).

      I was already able to get the number of denials by using set analysis something like (=sum({$<[TimeFrame]={'Time Frame 1'}, [ICDVariable Time]={'ICD1'}>} [Number of Denials Time]))

      But I see it's not that simple for the claim level.

       

      Any help would be greatly appreciated!

      ~Thanks