Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago

Operation - Update Datasources In Group on API don´t works for report with import model

Hello,

 

I´m trying to update a datasource from a report that uses import model. For this I used the Operation - Update Datasources In Group

of Power BI (https://docs.microsoft.com/en-us/rest/api/power-bi/datasets/updatedatasourcesingroup) .

Body Request:

 

 

{
"updateDetails": [
{
"datasourceSelector": {
"datasourceType": "Sql",
"connectionDetails": {
"server": "192.168.100.135",
"database": "db01"
}
},
"connectionDetails": {
"server": "192.168.100.135",
"database": "db02"
}
}
]
}

 

 


Body Response:

 

 

{ 
"error":{ 
"code":"InvalidRequest",
"message":"Operation is not supported for selector #1"
}
}

 

 


However, when I did the same for a report that uses DirectQuery, I´ve successfully.

 

Anyone can help me with this issue?

 

Thanks for your help!

1 Reply

  • v-kelly-msft's avatar
    v-kelly-msft
    Community Support

    Hi Anonymous ,

     

    What the data source are you connecting in Group? Whether the datasource have the same structure during updates?

     

    Best Regards,

    Kelly