Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SSRS. How to hide blank/empty column via expression?

I need to hide column if all rows in column is empty (blank).

In this case col3 should be hidden, because no values in column.

col1 col2 col3
 v1   v4
 v2
 v3   

I'm using following expression on columns Hidden property:

=IIF(Fields!Test5.Value = "",TRUE,FALSE)

This expression working, but It hidding each blank(empty) field, even all column isn't empty. It should hide column only when there is no values at all.

like image 641
Stanislovas Kalašnikovas Avatar asked Dec 25 '22 22:12

Stanislovas Kalašnikovas


1 Answers

You can use:

=IIF(Max(Field, Dataset)= "",TRUE,FALSE)

If the maximum value is empty it means that there is nothing, and make your hide expression on column.

like image 67
sdrzymala Avatar answered Jan 11 '23 06:01

sdrzymala