Monday, September 3, 2018

SSRS - Filling blank cells in matrix

In Reporting Services, tables, matrices, and lists are data regions that display paginated report data in cells that are organized into rows and columns. The cells typically contain text data such as text, dates, and numbers but they can also contain gauges, charts, or report items such as images. Collectively, tables, matrices, and lists are frequently referred to as tablix data regions.

Sometimes, when we have created a matrix/tablix/list with data in it, but there are quite a few blank cells where there is no data. In this case, we don't want to show the blank values on the report and we have to replace the blanks with zeroes.
There are some conditional expressions which can be helpful to full-fill this requirements-
  1. Just right click on the text cells and go to the expression
  2. In expression window, check if the cell contains Nothing then set 0 value else fill the actual value as given below- 

    =IIF(Fields!MyColumn.Value IS NOTHING , 0 , Fields!MyColumn.Value)

    If the field is empty or blank then it puts 0, otherwise it uses the actual data from the dataset.
Please watch a live demo at our YouTube Channel-

No comments:

Post a Comment