Getting a divide by zero error, but don't understand how

  • I'm getting a divide by zero error when testing, using a fairly short date range (the beginning of this month until today). But this is really weird. I'm using a stored procedure to do the calculations and then just feed that to the SSRS report. The SP has no problems whatsoever; no divide by zero errors at all there.

    In the SSRS report I either just render the field from the SP, or use something like:

    IIF(Fields!Field.Value < 0, 0, Fields!Field.Value)

    And in a few places I use the FLOOR and CEILING functions against values returned from the SP.

    Since the error is only coming from the SSRS report and now the SP, I have to believe the problem lives there. But I'm stumped trying to figure out what's wrong. I've checked every expression I've got in the report; nothing is using a division. Does some built-in function use division?

    Kindest Regards, Rod Connect with me on LinkedIn.

  • Just thought of something else to add to this. Years ago I was working with some other report generating product (I can't remember what it was now), but I believe it had a means of printing out every formula that was used in the report. Does SSRS 2012 have that ability?

    Kindest Regards, Rod Connect with me on LinkedIn.

  • Rod at work (5/19/2016)


    Just thought of something else to add to this. Years ago I was working with some other report generating product (I can't remember what it was now), but I believe it had a means of printing out every formula that was used in the report. Does SSRS 2012 have that ability?

    The RDL document is just an xml file. You should be able to open it in any xml/text editor and do a search.

    Drew

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • drew.allen (5/19/2016)


    Rod at work (5/19/2016)


    Just thought of something else to add to this. Years ago I was working with some other report generating product (I can't remember what it was now), but I believe it had a means of printing out every formula that was used in the report. Does SSRS 2012 have that ability?

    The RDL document is just an xml file. You should be able to open it in any xml/text editor and do a search.

    Drew

    Yeah!! Thank you!!!!

    Kindest Regards, Rod Connect with me on LinkedIn.

Viewing 4 posts - 1 through 3 (of 3 total)

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