Showing results for 
Search instead for 
Did you mean: 
JJenkins2005 Frequent Visitor
Frequent Visitor

Update Shared Datasouce for Report using PowerShell



We are in the process of migrating from SSRS to PBI-RS and have been testing reports in DEV using DEV Datasources.  We have over 300 reports, that we need to switch to Production Datasources, and I've been looking for a way to do it via powershell.. As a NOOB, I'm running into issues.   I downloaded the ReportingServicesTools and it looked like it would be pretty simple... NOPE...   I found that I should be using the Get-RSITEMDatasource and Set-RSITEMDatasource based on  my reading.. so I Ran the following:


PS C:\> $dataSources = Get-RsItemDataSource -ReportServerUri '' -RsItem '/docket/All Timekeepers'


Ran Succesfully


Then I ran



PS C:\> Set-RsItemDataSource -DataSource $datasources -RsItem '/AR/AR Aging' -ReportServerUri ''


I get the error below

Please use Set-RsDataSource to update shared data sources!
At C:\Program Files\WindowsPowerShell\Modules\ReportingServicesTools\\Functions\CatalogItems\Set-RsItemDataSource.ps1:143 char:17
+ ... throw "Please use Set-RsDataSource to update shared data ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : OperationStopped: (Please use Set-...d data sources!Smiley Frustratedtring) [], RuntimeException
+ FullyQualifiedErrorId : Please use Set-RsDataSource to update shared data sources!



I'm not trying to update the Shared Datasource itself... I'm simply tying to update the report to use another Shared Datasouce.. 


What am I doing wrong? 

Helpful resources


How to Get Your Question Answered Quickly

Power BI Super User, Greg Deckler, explains

Back to School Contest

Back to School Contest

Engage and empower students with Power BI!

MBAS Gallery

Watch Sessions On Demand!

Continue your learning in our online communities.

Top Ideas
Users Online
Currently online: 40 members 908 guests
Please welcome our newest community members: