Link to home
Start Free TrialLog in
Avatar of zrod
zrod

asked on

How to change data source of SQL report during runtime

Hello,
we are in teh process of migrating the reporting of our application to SQL reporting services.
We still need to solve teh following issue.
When we design a report, we do it it on a sample data Base.
Then this report is deployed with the application, and when the report is loaded into teh report viewer, teh application should be able to change the data source by .
the changes should apply only for this session, and not to all report, as another user or teh same user might run this report but based on another data dource.
any help?
Avatar of Howard Cantrell
Howard Cantrell
Flag of United States of America image

I would think that using Stored Procedures would be better.
The reports would not have to be changed. and you could have a set of SP to migrate to the customers SQL.
Avatar of zrod
zrod

ASKER

I do not get you.
Are you suggesting that we use a stored procedure to modify the data source of SQL reports during run time?
Your data source is your SP. No need to change at run time.
Avatar of zrod

ASKER

I think there is a mis-understanding.
What we need to change is teh server name, data base name . In fact the connection parameters .
zrod  are you still having problems with this report?
Avatar of zrod

ASKER

yes,
i did not get any solution till know,
i was unable to deploy an Sql  report to customers within my application.
Have you tried to copy the file to the server reporting directly and then run it?
Avatar of zrod

ASKER

Lets us take an example:
you have a query in our application  that returns data from one or multiple data bases.
When we deply the application at teh clients site, The user chooses the anme of the server, credentials and data base names.
So the report has been designed on data base x,y,z and now we need to run it on another set of data base. I do not see how teh copy will solve this issue.
I see what you are talking about. There may be no easy way, but to just enter new conection data depending on which server you use. I don't know if setting up database conections as parameters would work.
Avatar of zrod

ASKER

But setting up the database as parameters, will expose teh passwords,e tc... to the report.
it is amzing because we faced similar problem in VS2010. I wonder how microsoft reporting tools pretends to compote with Crystal report
Avatar of zrod

ASKER

corrected
But setting up the database as parameters, will expose the passwords,etc... to the report.
it is amazing because we faced similar problem in VS2010. I wonder how microsoft reporting tools pretends to compete with Crystal report.
You could just setup  the connection string ,but the user has to know the password to use it.
ASKER CERTIFIED SOLUTION
Avatar of zrod
zrod

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial