0
votes

I have Developed a new SSRS report. I added a new tablix in it and in that tablix added two columns called "Total Incidents logged" and "Total Security Incidents logged".I gave row visibility and mention the following expression. =iif(Fields!SecurtiyIncidents.Value = 0,true,false)

So i hide those rows in which values of security Incidents contains 0. But the problem is, in total column of Total Incidents logged, it contains the hide values also. I googled and found only those answers which contains only one Column and people gave row visibility. But in my case there are 2 columns.

For better understanding, i have added images. In first image, the normal table is there with total

in second picture, given row filtration on Security Incidents Logged, i.e =iif(Fields!SecurtiyIncidents.Value = 0,true,false)(So i hide those rows in which values of security Incidents contains 0) but if you see total of Incidents logged, it not changed. :(

Could anyone please help me out?

enter image description here

enter image description here

enter image description here

3

3 Answers

1
votes

You are putting two different values in one row.
You are telling SSRS to hide that row if one specific value in that row is zero.
When that value is zero, the whole row is hidden and you are wondering why?

Either put the values in different rows, set the column visibility using your expression above or simply set the value of the text box to be =iif(Fields!SecurtiyIncidents.Value = 0,"",Fields!SecurtiyIncidents.Value)

0
votes

Filter the tablix: Fields!SecurtiyIncidents.Value <> 0

Hiding the row only modify the display, the calcs/totals remains normal.

0
votes

If you are hiding each row that has zero values in one or both fields you can use a conditional SUM in the total row as follows.

For No of Incidents Logged column use:

=SUM(IIF(Fields!SecurityIncidents.Value>0,
Fields!IncidentsLogged.Value,
0))

For No of Security Incidents Logged use:

=SUM(Fields!SecurityIncidents.Value)

Let me know if this helps.