Report result set smaller than expected

(4 posts) (2 voices)

Tags:

No tags yet.

  1. -nth-, Member

    I've got a weird issue I'm trying to track down. I've got a report that is "missing" rows. It's got several date parameters that get assigned to a sql "WHERE datefield BETWEEN dateparam1 AND dateparam2" clause. The issue is that when the report is run with a large date range, the result set is smaller than it should be. As an example, I ran the dbr report and got 30 rows, then copied the exact sproc statement from the statistics table and ran it in Sql Server Management Studio (SSMS) and it returned 33 rows (which is correct). This report has other parameters besides the date ones, but this issue seems related to the dates somehow. Any known issues regarding this? Or suggestions for further investigation?

    Thanks,
    -nth-

    Forgot to mention I'm running myDBR 3.4.0 (build 1415)

  2. myDBR Team, Key Master

    myDBR will show all results coming from the server. If you are getting a different result set back from myDBR compared to SSMS, the most likely cause of this is some connection specific setting. Check also that your date settings are correct (month vs day).

    To narrow down the problem, run the report directly from myDBR's Query Browser so you get the exact output and simplify the query to narrow down the cause of it.

    --
    myDBR Team

  3. -nth-, Member

    When troubleshooting the report, for performance reasons, I took the time to rebuild several joins on different columns and the problem went away. Still not sure why I got 2 different result sets with the other way, but the problem is now solved!

  4. myDBR Team, Key Master

    You can use SESSIONPROPERTY to show session information on both environments as different settings may affect the query execution.

    --
    myDBR Team


Reply

You must log in to post.