I’m having trouble with an SSRS Expression. I am trying to get a distinct count of records for records that end in September. I am using the following code:
=(countdistinct(IIF(Fields!dischargemonth.Value = "September" and Fields!RowNumber.Value = 1, Fields!AuthId.Value, 0)))
The correct count should be 28. I have double checked the query and there are only 28 records, but my output results in SSRS is showing 29.
I’ve tried using “COUNT” but I only want the distinct count of records so that won’t work. Any ideas on why this would occur?
Thank you in advance for your help.
Thank you for the insight Dave. So instead of using “0”, I updated the code to
And now the count shows 28, which is correct.