I deployed a report via Write-RsCatalogItem. In the past it referred to a shared data source, however the new RDL uses an embedded data source with an expression-based connection string.
After deployment it still referred to the shared data source. I was able to change it via the portal:
- Manage → Data sources → Change to A custom data source
- Set the connection type, enter a bogus connection string and choose credentials
- After saving and reloading there will be a Revert to default under the connection string, click that to use the expression
- Save
However, I am not sure how to do this with this module.
I noticed it works correctly for new reports that have no existing data sources to change, however.
So, is the only workaround to rename the data source?