Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
mewisenb
New Member

Automating export/download of Linked Report

Is it possible to automate downloading/exporting a Linked Report as a regular user?  I've been futzing around with the SSRS powershell module, but have not made much headway. 

1 ACCEPTED SOLUTION
d_gosbell
Super User
Super User

If the original report uses data sources with stored credentials you should be able to setup a report subscription to output the report to a file on a scheduled basis. But if the report uses windows authentication this is not possible.

 

If you wanted to use powershell you could use url access to get an export of the report see  https://docs.microsoft.com/en-us/sql/reporting-services/export-a-report-using-url-access?view=sql-se... 

 

So you could use something like the following:

 

Invoke-WebRequest -Uri "http://localhost/reportserver?/Demo%20Reports/Products%20by%20Colour&ProductColor=Black&rs:Format=EXCELOPENXML" -OutFile "c:\temp\report.xlsx" -UseDefaultCredentials

 

I ran this on my local dev server and it exports the "Products by Colour" report with a parameter value of "Black" and outputs the results to an excel file.

View solution in original post

2 REPLIES 2
d_gosbell
Super User
Super User

If the original report uses data sources with stored credentials you should be able to setup a report subscription to output the report to a file on a scheduled basis. But if the report uses windows authentication this is not possible.

 

If you wanted to use powershell you could use url access to get an export of the report see  https://docs.microsoft.com/en-us/sql/reporting-services/export-a-report-using-url-access?view=sql-se... 

 

So you could use something like the following:

 

Invoke-WebRequest -Uri "http://localhost/reportserver?/Demo%20Reports/Products%20by%20Colour&ProductColor=Black&rs:Format=EXCELOPENXML" -OutFile "c:\temp\report.xlsx" -UseDefaultCredentials

 

I ran this on my local dev server and it exports the "Products by Colour" report with a parameter value of "Black" and outputs the results to an excel file.

d_gosbell,

 

This worked a treat!  I really do appreciate your help.  For whatever reason we don't have the permissions to create subscriptions.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.