views:

553

answers:

1

I have created a report in SSRS that contains 2 matrices (not tables/lists), each with a subtotal. What I am trying to work out is if there is any way to calculate a 'grand total' at the bottom of my report that is the sum of the subtotals from my 2 matrices.

Matrix 1:
10 10 10 5 10 5 5 Total 55

Matrix 2:
20 10 10 5 20 5 5 Total 75

Grand Total: 130

Each matrix is driven from a separate datasource btw.

Essentially what I am trying to end up with is

=sum(fields!gross.Value,"matrix1")+sum(fields!gross.Value,"matrix2")

as grand total, but this doesn't work.

As I said, I'm new to this so the above syntax may be incorrect, though I hope it gives you an idea of what I am trying to achieve.

Is this even possible?

Thanks

+2  A: 

Instead of using "matrix1" and "matrix2" use the name of the dataset for each one.

 =sum(fields!gross.Value,"Dataset1") + sum(fields!gross.Value,"Dataset2")

Also, sometimes if your data types are not explicit, you will have to cast your fields like so:

 sum(CDec(fields!gross.Value),"Dataset1")

But you will probably not have to do that in this case.

Dustin Brooks
Thanks - I'll give this a try on monday and see if it does work. Cheers
Nic Wise
Yup, that worked great. Thanks!!
Nic Wise