x

SSRS executes SP with 24 Result Lines - How do I get all 24 results in SSRS?

I am converting reports from Brio to SSRS. Brio is using SP’s so I already have my data sources. SP has one parameter, the date (ex. ‘11/30/2010’). My only problem is that when the SP executes at the end there are 24 select statements, one for each 1 hour period of the day (12am-1am, 1am-2am, etc.) so I get 24 “results”. The Brio report handles this fine and I get the reports/charts I want. I am having a little trouble in SSRS figuring out how to get the same results. When I add this SP as my dataset and execute it, I only get back the results for first select statement of the 24 – 12am-1am. I do not want to rewrite all of the stored procedures, or have to change any of them. Any ideas how I can handle this in Reporting Services?
more ▼

asked Dec 01, 2010 at 04:36 AM in Default

kickinwing gravatar image

kickinwing
31 3 3 3

(comments are locked)
10|1200 characters needed characters left

1 answer: sort voted first

SSRS only will handle the first result set.

MSDN/BOL:

Only the first result set that is retrieved for a stored procedure is supported. If a stored procedure returns multiple result sets, only the first one is used.

You will need to either:

  • union the selects together
  • create new procs for each result set

but if you don't want/can't change the procs, then you are stuck!

In the meantime, go to [Connect][2] and vote this feature up!

[2]: http://connect.microsoft.com/SQLServer/feedback/details/125454/reporting-services-recognize-multiple-result-sets-returned-from-a-stored-procedure
more ▼

answered Dec 01, 2010 at 04:47 AM

Kev Riley gravatar image

Kev Riley ♦♦
53.8k 47 49 76

(comments are locked)
10|1200 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

New code box

There's a new way to format code on the site - the red speech bubble logo will automatically format T-SQL for you. The original code box is still there for XML, etc. More details here.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

SQL Server Central

Need long-form SQL discussion? SQLserverCentral.com is the place.

Topics:

x558
x415

asked: Dec 01, 2010 at 04:36 AM

Seen: 905 times

Last Updated: Dec 01, 2010 at 04:36 AM