Summing a calculated field

  • Hello

    Pietlinden kindly offered yesterday the following expression to add to a calculated field:

    =IIF(fields!date1.value>fields!date2.value,1,0)

    I have added this to my dataset, and it is putting a 1 or 0 next to the date column.

    However, when I came to total it, by putting SUM(fields!totals.value = 1), I get #Error.

    Note I have added this as a total outside of the group.

    Any suggestions on how to get a total of all the 1's would be appreciated - thanks. I thought maybe it was seeing the 1's as text values, something like that.

  • Note that I've just realised I put "1" and "0" in the queries - removing " " makes the sum work fine

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply