Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
cutlerz
New Member

Dataset doesn't contain a datasource that matches selector #1 exception

I develop Power BI Embed reports project and it has ever worked fine before since I update Power BI desktop when I modify some reports and publish it to Power BI workspace.

Now when my updated Embed report is clone to new workspace and try to update with new DB connection string.

this API method is broken it cannot update DB connectionstring and marked is obsoleted.

"await client.Datasets.SetAllDatasetConnectionsInGroupAsync(GroupId, dataset.Id, connDetail)"

The error throws something like this

"{"error":{"code":"PowerBIUpdateMetadataUnsupportedModelWithV3DataSourceException","pbi.error":{"code":"PowerBIUpdateMetadataUnsupportedModelWithV3DataSourceException","parameters":{},"details":[],"exceptionCulprit":1}}"

 

So I try to fix my codes to use new Microsoft.PowerBI.Api version 3.14.0.0 by updating NuGet Package and try to use this new method in the example below but it still does not work and the new error throw instead

"{"error":{"code":"ItemNotFound","message":"Dataset doesn't contain a datasource that matches selector #1"}}"

 

My some codes example:

var datasourcesRequest = new UpdateDatasourcesRequest()
{
UpdateDetails = updateDataSourceDetails
};

try
{
    await client.Datasets.UpdateDatasourcesInGroupAsync(groupId, dataset.Id, datasourcesRequest);
}

catch (HttpOperationException exHttp)
{  

    _logger.LogError(exHttp, exHttp.Response.Content);

}

 

Any helps would be appreciate, Thanks in advance.

 

2 REPLIES 2
Anonymous
Not applicable

Hi @cutlerz,

Have you tried to clean up and rebuild your solutions? I'd like to suggest check if the old library files remain in your projects which may affect the last version codes.

Regards,

Xiaoxin Sheng

Greg_Deckler
Community Champion
Community Champion

@cutlerz You could check the Issues forum here:

https://community.powerbi.com/t5/Issues/idb-p/Issues

And if it is not there, then you could post it.

If you have Pro account you could try to open a support ticket. If you have a Pro account it is free. Go to https://support.powerbi.com. Scroll down and click "CREATE SUPPORT TICKET".



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.