Tuesday, March 20, 2012

Change Datasource connectionstring

Hey,

I have a SQL Server 2005, an Reporting Services is also installed.
Now I have a report 'Report1' and a datasource 'DS1', the report is build and deployed.
The report works fine when i see it in a browser.

Now I have made a vb.net application with a dataviewer, the dataviewer shows the report 'Report1'.
But I want to be able to change the datasource 'DS1' from my application code.

How can I do this?

thanks

Hi,

you could use a hidden parameter which will influence the beahaviour of a dynamic evaluated connectring string, though connection strings can be designed dynamically like ="Data Source" + IIF(Parameters!SomeParam.Value = 1, "SomeServer",SomeOtherServer") That is a thing which is most common, enabling you to do this also on the brwoser interface by just manipulating the URL of the Report.


HTH, Jens K. Suessmeyer.


http://www.sqlserver2005.de

No comments:

Post a Comment