Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
lols
Posting Yak Master
174 Posts |
Posted - 2007-08-24 : 00:23:16
|
Hi all,I have tried asking the same question in other forums. The answer I get is a couple of links which mean nothing :( Please help me. I have the following requirement:I have the following tables:Theater - TheaterId, TheaterName, Revenues,locationid, stateidState - StateId, StateNameLocation - LocationId, LocationName, StateIdI want to generate reports that will tell me the revenue generated for each theater in each location in a state. I want to run a batch process which will loop through the 3 tables and will passing the location and state id as parameters one by one. I want each report to be generated as a pdf and stored in a location. How do I do this?Thanks. Gurus please help me. |
|
lols
Posting Yak Master
174 Posts |
Posted - 2007-08-27 : 00:46:45
|
Hi,I have figured a lot of things in this. Please help me solve this query now :I am calling xp_cmdshell from inside a stored procedureEXEC master.dbo.xp_cmdshell 'rs.exe -i "C:\Program Files\Microsoft SQL Server\90\Samples\Reporting Services\Script Samples\Sample1.rss" -s http://localhost/reportserver -v param1="10" -l 0 -e mgmt2000 -t -b'in the .rss file, i use the following : Dim parameters(1) As ParameterValue parameters(0) = New ParameterValue() parameters(0).Name = "s_no" parameters(0).Value = param1My Question is how do I pass dynamic values in param1. I have a variable in my stored proc called @s_no which i try to pass, however it is not working. EXEC master.dbo.xp_cmdshell 'rs.exe -i "C:\Program Files\Microsoft SQL Server\90\Samples\Reporting Services\Script Samples\Sample1.rss" -s http://localhost/reportserver -v param1=@s_no -l 0 -e mgmt2000 -t -b'Can anyone suggest how to do this?Over here, I want to pass the value of param1 dynamically. |
|
|
|
|
|
|
|