I'm facing an issue with SSRS reports. Below is the scenario.
I have SSRS reports with embedded DataSource configured to point dynamically to different databases. I'm achieving this by passing the Connection String as a parameter to the report.
The following is the expression used in the DataSource:
="Data Source = "& Parameters!Server.Value &"; Initial Catalog = "& Parameters!Database.Value &";"
This works fine for a report which does not require the available values to be populated dynamically from a query.
In a scenario where the parameters needs to be populated dynamically from a query this doesn’t hold good. If I run the report with the same configuration I'm getting the following exception “Error during processing of the ConnectString expression of data source”.
I understand this is because the Report has to connect to the database to populate the parameter values and we are passing the connection string only when the report is executed.
Is there any way to achieve Dynamically populated parameters with Dynamic DataSource in SSRS? I'm using SQL Server 2008 R2.
Any help is highly appreciated. Thanks!