4 Replies Latest reply on Mar 28, 2016 11:52 AM by casey lee

    How to calculate

    casey lee

      I'm trying to calculate

      {(CoolingDegreeDays)+(HeatingDegreeDays)}/(Load Total)

       

      Since these field in the same column. I'm not sure how to calculate in above way.

       

      Could you please help.

       

      Thank you

       

        • 1. Re: How to calculate
          Derrick Austin

          Hey Casey,

           

          Something like this should work:

           

          (SUM(IF [Pointname] = 'CoolingDegreeDays' THEN [Units] END) + SUM(IF [Pointname] = 'HeatingDegreeDays' THEN [Units] END))

          /

          SUM(IF [Pointname] = 'Load Total' THEN [Units] END)

          • 2. Re: How to calculate
            pooja.gandhi

            You could use LOD for this:

             

            ({ fixed [Segment], [Category] : sum(if [Ship Mode] = 'Same Day' then [Quantity] end )} + { fixed [Segment], [Category] : sum(if [Ship Mode] = 'First Class' then [Quantity] end )} ) / { fixed [Segment], [Category] : sum(if [Ship Mode] = 'Second Class' then [Quantity] end )}

             

             

            So here it is taking , 251+594 / 868.

             

            You can change the pills based on what you have!

            • 3. Re: How to calculate
              casey lee

              Hi

              Pooja,

               

              I used your calculation and i believe it should work... but somehow # doesn't matched.

              I used below calculation but it resulting something else. Could you please help? could it be due my numeric value?

               

              if you look at my screenshot site =10  with calculation below. it should equal to 4 instead of 1824...

               

              • 4. Re: How to calculate
                casey lee

                I found the problem

                the problem is its calculating through every days..

                Is there anyway I could calculate based on the filter selection as date or??

                 

                As you can see on the below screenshot, after clear out the filter.

                CoolingDegreeDays=953

                HeatingDegreeDAys = 871

                which equals to 1824  and 1824 was the result after using calculation.