SSRS 2005 - calculate list total

Posted on 2006-04-10
Last Modified: 2008-02-01
Hi Experts,

I've got the following data set in a matrix report:

                      Variety1    Variety2    Variety3
Mass (tons)         4             6                 9
Crates                340           510            750
Cartons Class1     1105        6543           8754
Cartons Class2      6543        7654          8754
Cartons Class3      6554        8765         8765

I'm using SQL Server Reporting Services 2005 and I'm trying to add an additional field at the bottom to display the total cartons for Variety1 , Variety2 etc. I don't know how to write the expression to calculate the carton totals so any help would be much appreciated.  
Question by:avdvyver
    LVL 14

    Expert Comment

    If your using a Matrix control, you should be able to right click the data cell you want to total, and then Right click and select Sub Total.

    Author Comment

    Hi Simon,

    I'm already using the sub total function to display the totals on the right side of the report. What I'm trying to do here is to sum 3 data fields and display the total underneath it. I can use the following expression but this totals all the cartons (class 1, 2 and 3) and per variety:

    =Sum(Fields!tot_ctns_c1.Value, "SQLDB") + Sum(Fields!tot_ctns_c2.Value, "SQLDB") + Sum(Fields!tot_ctns_c3.Value, "SQLDB").

    Is this the type of thing that you recon must be calculated at query level or you know if SSRS provides the functionality to make these sort of calculations?

    Author Comment

    Sorry ... typo in the above msg. The expression above calculates the total cartons (class 1,2 and 3) regardless of variety. I need the totals (class 1,2 and 3) per variety. Hope that makes sence.
    LVL 14

    Accepted Solution

    You can add sub totals to the right and bottom of a matrix control. Right click the row group and add the sub total.  

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Do You Know the 4 Main Threat Actor Types?

    Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

    Suggested Solutions

    Hi, In my previous Article  ( discussed some basic understanding of Microstrategy that how we can get in Intro of Microstrategy (MSTR). Now it's tim…
    From implementing a password expiration date, to datatype conversions and file export options, these are some useful settings I've found in Jasper Server.
    Sending a Secure fax is easy with eFax Corporate ( First, Just open a new email message.  In the To field, type your recipient's fax number You can even send a secure international fax — just include t…
    Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    22 Experts available now in Live!

    Get 1:1 Help Now