Forum Discussion
Create Dataset with datasource programatically
Hi lbendlin
Thanks for the quick response.
But API doesn't allow me to modify the dataset which is created on Local instance.
{
"error": {
"code": "ItemNotFound",
"message": "Dataset <dataset_id> is not Push API dataset."
}
}
Also, it doesn't allow me to push a Datasource with a dataset.
https://docs.microsoft.com/en-us/rest/api/power-bi/pushdatasets/datasets_postdataset
The above endpoint documentation says, it takes data source property in the request, but when I add one it throws below error
{
"error": {
"code": "BadRequest",
"message": "Bad Request",
"details": [
{
"message": "The property 'datasource' does not exist on type 'Microsoft.PowerBI.ServiceContracts.Api.Dataset'. Make sure to only use property names that are defined by the type.",
"target": "dataset"
}
]
}
}Is there any way I can link the data source to the custom dataset?
Thanks
Seethend
Correct, you can only do that in the service, not locally. (of course if you are adventurous enough you could download the .pbix, then manipulate the meta data in the .pbix, and then upload it again.)
I'll play with my push dataset a bit to see if I can reproduce your errors.
- jithin5 years agoNew Member
Hi,
have you found any solution to this problem yet?
I am facing the same issue with push dataset - not able to include datasources in request.
- Anonymous5 years agoNot applicable
Same. When trying to add a datasource in the request it blows up