Conditional Subtotal of Columns in Matrix -SSRS 2005
I have weekly Cost and Quantity values in columns that are grouped by month. I need to get the Montly subtotal for the Cost column but not for the Quanity column (since this is not additive). When I put the subtotal into the matrix I get a subtotal for Cost and Quantity. How can I hide the Quantity subtotal or prevent this from occurring?
TIADean
September 9th, 2008 6:35pm
Hello,If you don't want to display the quantity data in the sub total row then add this expression for displaying of quantity data.Expression:=IIF(Inscope("GroupName"),Sum(Fields!Quantity.Value),"")Hop helpful...Thanks,PavanPavan
Free Windows Admin Tool Kit Click here and download it now
December 25th, 2008 3:31pm
Where do I add itMr Shaw
April 3rd, 2009 2:10pm
Hello,Ad this in the cell where you want to display the quantity field.Hope helpful..Pavan
http://www.ggktech.com
Free Windows Admin Tool Kit Click here and download it now
April 3rd, 2009 3:26pm
It is not possible to do this since the cell which I would add it to is part of the defualt subtotal. Therefore I am not able to access it in desgin view.Mr Shaw
April 3rd, 2009 3:31pm
Here's what I used in my report to hide the subtotal column based on a condition:
In the visibility property of the textbox that displays the main data of the matrix, I put
=iif(countdistinct(fields!SOMEFIELD.Value) > 1, IIF(Inscope("matrix3_RowGroup2"),True,False), IIF(Inscope("matrix3_RowGroup2"),False,True))
I'm checking to see if the total number of items in the rows are greater than 1.
If there is more than 1, I want to display the subtotal, otherwise hide the cell.
To get something like this working on different groups, you'll want to add another if statement to first check which group you are in.
For example, iif(Fields!myGroup.Value = "Group1", .......
Hope this helps someone.
-The Nub
Free Windows Admin Tool Kit Click here and download it now
May 25th, 2011 2:21pm