Skip to content

Conversation

@sqlkabouter
Copy link
Contributor

There reference name was pointing to the XML element 'SharedDataSet' instead of the actual name of the DataSet.

There reference name was pointing to the XML element 'SharedDataSet' instead of the actual name of the DataSet.
@mmajcica
Copy link
Owner

mmajcica commented Jun 30, 2018

Datasets are the only thing I added but I was not able to test them.
I am confident that your change is genuine. I'll merge this and publish a new version.

Thank you for your contribution.

@mmajcica mmajcica closed this Jun 30, 2018
@mmajcica mmajcica reopened this Jun 30, 2018
@mmajcica mmajcica merged commit 90a4318 into mmajcica:master Jun 30, 2018
mmajcica pushed a commit that referenced this pull request Oct 5, 2018
…erence

Updated the DataSet reference name
@sebitsi
Copy link

sebitsi commented Apr 1, 2019

Hi @mmajcica and @sqlkabouter.

I think there is bug in concept how shared datasets are referenced.

Look into this part of code (lines 954+):

If ($ReferenceDataSets -and $DataSets)  {
    $nodes = $Definition.SelectNodes('d:Report/d:DataSets/d:DataSet/d:SharedDataSet/d:SharedDataSetReference/..', $NsMgr)

     foreach($node in $nodes)
     {
          @($Datasets | Where-Object { $_.Name -eq $node.ParentNode.Name }) | ForEach-Object { $node.SharedDataSetReference = $_.Path }
     }
}

In this code dataset's name defined in config file is compared to node.ParentNode.Name.
In si not correct because ParentNode.Name is name of report's datatable not shared datatable.
Shared datatable's name is inside $node.

If report's datatable has reference to shared datatable with same name there is no problem.
But if names are different, task will not match it.

@sqlkabouter sqlkabouter deleted the fix-New-SsrsReport-DataSet-reference branch March 10, 2020 16:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants