0
votes

Currently, I have a report on SSRS ( SQLServer 2008R2) and accept a invoice number as a parameter. The report will generate the information related to this invoice in 1 report. So, 1 invoice 1 report. If I need to generate 2 invoices, I need to run twice.

I would like to schedule it and generate reports automatically once the invoice appears in the database and save the output as PDF for each in a unique file name.

Just wonder what's the best option for me to do it

1) Use SSIS. Create a For..Loop to execute a SQL statement to return all invoices that fulfills the criteria and then call SSRS report.

2) In SSRS, there's a subscribe option but I can't find any way I can pass in the parameter automatically and for multiple times. Or some configuration that I missed out ?

Hope you can provide me some ideas. Thanks.

1
You can also write windows service. Which will be more flexible. - Mahesh

1 Answers

0
votes

both 1 and 2 would work. To me, I think 2 is better.

2) In SSRS, there's a subscribe option but I can't find any way I can pass in the parameter automatically and for multiple times. Or some configuration that I missed out ?

I found this on Microsoft site which covers how to pass in parameter value to report. Hope it is helpful.

https://msdn.microsoft.com/en-us/library/ms166561(v=sql.105).aspx