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

# Add columns of data together in the Table Window

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

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

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

Hello Guy,

If your report data looks like:

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:

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

• ###### Add columns of data together in the Table Window

Thanks for the assistance but  the Field+ options does not work as I had tried something similar.

I also need the total in the Table not the summary. This report output has to be exported as a file to be uploaded to another program otherwise I would do the formula in excel etc.

Any other ideas?