I'm trying to deploy a dataset with a reference to an existing data source, but some how code example down below is not working. It's still pointing to the data source that I had defined locally inside my report project.
So on my SSRS server, I have different data sources: TST_DATASOURCE and PROD_DATASOURCE. Locally, I point to 'PROD_DATASOURCE'. However, on my SSRS server I have various folders that use different data sources. Thus, meaning that I also have different report configs like: reportconfig.tst.json and reportconfig.prod.json.
Folder TEST uses the TST_DATASOURCE and PROD uses the PROD_DATASOURCE. Therefore, I want to automate this process by using a different data sources in my reportconfigs.
When I manually choose the existing data source, then it's working but when I try to configure everything through the json configuration file this seems not to be working. So I'm trying to make it happen that I do not configure this manually, but in an automated manner through json.
I'm using the following: Deploy SSRS Task
reportconfig.prod.json:
{
"Name": "PROD",
"Folders": [
{
"Name": "ReportsArchive",
"Reports": [
{
"Name": "Report",
"FileName": "Report.rdl"
}
]
}
],
"DataSets": [
{
"Name": "SharedDataSet_PROD",
"FileName": "SharedDataSet_PROD.rsd",
"Hidden": true,
"DataSources": [
{
"Name": "DataSetDataSource",
"DataSourceReference": "/PROD/PROD_DATASOURCE.rds"
}
]
}
]
}
reportconfig.tst.json:
{
"Name": "TEST",
"Folders": [
{
"Name": "ReportsArchive_TEST",
"Reports": [
{
"Name": "TestReport",
"FileName": "TestReport.rdl"
}
]
}
],
"DataSets": [
{
"Name": "SharedDataSet_TST",
"FileName": "SharedDataSet_TST.rsd",
"Hidden": true,
"DataSources": [
{
"Name": "DataSetDataSource",
"DataSourceReference": "/TEST/TST_DATASOURCE.rds"
}
]
}
]
}
Local the reference is: PROD_DATASOURCE.rds but since it's remote on the SSRS server, i need to provide the remote folder structure path but i'm not sure if I do this correctly (i.e. is the json structure for DataSources correct?)
The new datasets are being created succesfully, except for the data sources. On this page, when I visually inspect this it says that the data source couldn't be found.. so it's pointing to the wrong data source and not to the remote one while I defined this?