9 Replies Latest reply: Oct 13, 2011 4:44 AM by julierizkallah RSS

    Sum records based on a condition


      I would like to Sum the [# sent] and [# sent on time] for each country when I select specific months. For the below example, if I select Jan-11, Feb-11, and Mar-11, I need to have the total for each country according to the months selected.


      Original table is

      CountryMonth# sent# sent on time% on time
      Country AJan-1144100.00
      Country AFeb-115480.00
      Country AMar-1133100.00
      Country BJan-1177100.00
      Country BFeb-1122100.00
      Country BMar-118787.50
      Country CJan-1155100.00
      Country CFeb-111010100.00
      Country CMar-1111100.00
      Country DJan-1144100.00
      Country DFeb-119888.89
      Country DMar-1177100.00


      I need the totals to figure in a table as per the below. the percentage is recalculated based on the new numbers.

      # sent# sent on time   % on time
      Country A121191.67
      Country B171694.12
      Country C1616100.00
      Country D201995.00


      I would highly appreciate your help,