3 Replies Latest reply: May 15, 2014 10:08 AM by guyporter _ RSS

    Add columns of data together in the Table Window

    guyporter _

      I am having trouble with an extraction where I need to add the data in 4 colums together to give one total. This needs to be done in the table window so I can hide the source etc.

      Columns are

      Heading 1/30,,  30/60,,  60/90,, 90/120,,Total

      Numbers 50,,,,,,,,50,,,,,,,,,50,,,,,,,,50

      In the (not terribly good example above) I need a calculated field formual to sum the data in the three columns to give me the total of 200 in the new calculated field. I have tried all sorts of terms without success (I am sure its a simple formula.) I cannot adjust the template painting to get it all in one.

      Any help would be much appreciated.

      Thanks

        • Add columns of data together in the Table Window
          mdyoung _

          Hi, Guy.

           

          I'm going to take into consideration the columns you wish to sum are of the numeric data type. On the table view, create a calculated field titled "Total" and make it a numeric data type as well. In the formula section, add the following expression:

           

          Field1 + Field2 + Field3 + Field4[/SIZE]

           

          Hope this helps.[/SIZE]

           

          Micheal[/SIZE]

            • Add columns of data together in the Table Window
              Olly Bond

              Hello Guy,

               

              If your report data looks like:

               

              Heading 1/30 31/60 61/90 91/120

              Data A  50   60   70   80

              Data B  40   30   20   10[/CODE]

               

              then you might find a multi-column region to be the easiest solution. This would give you a table like:

               

              Data - Heading - Value

              A - 1/30 - 50

              A - 31/60 - 60

              A - 61/90 - 70

              A - 91/120 - 80

              B - 1/30 - 40

              B - 31/60 - 30

              B - 61/90 - 20

              B - 91/120 - 10[/CODE]

               

              You can then get the totals easily in a summary.

               

              Best wishes,

               

              Olly