all groups > sql server reporting services > february 2005 >
You're in the

sql server reporting services

group:

Changing Databases


RE: Changing Databases Vipul Shah
2/3/2005 2:11:03 PM
sql server reporting services: What you do is write a stored procedure for your sql need in third database
other than those two and write in a way that it can accept database name and
then fully qualify your object name and build a dynamic sql in the proc. Use
this proc in RS to buid one dataset and create another dataset with simple
query like "select dbname from sysdatabases where <criteira of your
interest>". Use this dataset as a input to the parameters of the first
database so the final report will have at least one parameter to pick a
database name from the dropdown list and you can run your report off of
selected database. I have implemented this way and I am running my report
off of more than two database from one server and it works great. Let me
know if you have any difficulties. email me.

Vipul Shah

[quoted text, click to view]
Changing Databases Nick Jacobs
2/3/2005 4:39:38 PM
I have two databases on the same SQL server which have identical data
structures.
I want to be able to use one set of reports on my report server to run
against either database. How can I achieve this? Whenever I run the report
it always runs against whatever the datasource points at.

Nick

AddThis Social Bookmark Button