timabell / ssrs-powershell-deploy

PowerShell scripts to deploy a SQL Server Reporting Services project (*.rptproj) to a Reporting Server
MIT License
75 stars 40 forks source link

The report server cannot process the report or shared dataset #5

Closed timabell closed 9 years ago

timabell commented 9 years ago

deploy now runs without error, but running the freshly deployed report gives me

The report server cannot process the report or shared dataset. The shared data source 'XXXXData' for the report server or SharePoint site is not valid. Browse to the server or site and select a shared data source. (rsInvalidDataSourceReference)

LouOtway commented 9 years ago

We've managed to work around this problem by taking the previous version and, when the invalid data source throws an exception (see: https://github.com/timabell/ssrs-powershell-deploy/issues/2), catching it and re-deploying.

timabell commented 9 years ago

@LouOtway so you mean the older version of this script correctly fixed-up the datasource for you?

Dang. Flail.

Incidentally the web ui for the report says "The shared data source reference is no longer valid" with a yellow exclamation sign.

LouOtway commented 9 years ago

Hi Tim

Our workaround was to use the older version and run the deploy script twice, catching the first exception.

Other than that it's great, we loved not having to mess about with that broken web api.

Cheers On 20 Apr 2015 4:14 pm, "Tim Abell" notifications@github.com wrote:

@LouOtway https://github.com/LouOtway so you mean the older version of this script correctly fixed-up the datasource for you?

Dang. Flail.

Incidentally the web ui for the report says "The shared data source reference is no longer valid" with a yellow exclamation sign.

— Reply to this email directly or view it on GitHub https://github.com/timabell/ssrs-powershell-deploy/issues/5#issuecomment-94480580 .

timabell commented 9 years ago

I've just pushed some commits that add a test ssrs project, which also breaks, thus eliminating anything to do with my client's project.

timabell commented 9 years ago

I agree, oh and I didn't originally write this script, I just put it on github so it was possible to work on it.

timabell commented 9 years ago

stepping through I see that although $DataSources is populated, SetItemDataSources() isn't being called.

https://github.com/timabell/ssrs-powershell-deploy/blob/bbd287f80f2a876b1d99f098e7aa14f7be1ee71f/Deploy-SSRSProject/Deploy-SSRSProject.ps1#L232-L234

timabell commented 9 years ago

Powerhell is such a horrible language. All fixed, it was just me and my size 9s trampling all over the script without understanding it.