• doug.brown (3/13/2014)


    Would something like this work?

    =IIF(Fields!Employee.Value Is Nothing, "0", SUM(IIF(Fields!Employee.Value = "FullTime",1,0),"Production") ) --- This will give the sum of Fulltime employees

    =IIF(Fields!Employee.Value Is Nothing, "0", SUM(IIF(Fields!Employee.Value = "Partime",1,0),"Production") )---- This will give the sum of Part Time employees

    =IIF(Fields!Employee.Value Is Nothing, "0", Count(Fields!Employee.Value,"Production") )--- This will give a count of all employees

    This won't work because SSRS will not attempt to do anything with the tablix if there are no rows in the associated dataset.

    You can configure the "NoRowsMessage" of the tablix but I suspect that this won't do what is needed.

    I think that you will need to change the SQL code you are using so that there is at least one record returned. If that record contains values that are not included in the SUM expressions (i.e. the IIF statements return 0), that will work OK. The employee count expression would need to be changed to exclude that record.