Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
I have application in C# than use TOM to connect to Power BI workspace and then go through existing datasets and retrieve M Query.
But dataset created automatically from datamarts is not available in TOM collection.
Should I analyse this "new type" of dataset differently? Is it supported by TOM?
Thx.
David
string workspaceConnection = "powerbi://api.powerbi.com/v1.0/myorg/" + workspacename;
string tenantId = _configuration["tenant"];
string appId = _configuration["client_id"];
string appSecret = _configuration["client_secret"];
string connectStringApp = $"DataSource={workspaceConnection};User ID=app:{appId}@{tenantId};Password={appSecret};";
// connect to the Power BI workspace referenced in connect string
Microsoft.AnalysisServices.Tabular.Server server = new Microsoft.AnalysisServices.Tabular.Server();
server.Connect(connectStringApp);
//Database = Datasets -> not see datasets from Datamarts
foreach (Microsoft.AnalysisServices.Tabular.Database db in server.Databases)
{
I'm sorry but these links describe datamarts from end-users perspecive not developers.
I have also tried REST API and get unnamed dataflow from workspace with datamart.
But when I tried to get dataflow json I got error reponse.
{
"error": {
"code": "InvalidRequest",
"message": "Unexpected dataflow error: "
}
}
For "standard" dataflow, the response is ok.
https://api.powerbi.com/v1.0/myorg/groups/....../dataflows
https://api.powerbi.com/v1.0/myorg/groups/..../dataflows/...
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 |
| User | Count |
|---|---|
| 4 | |
| 4 | |
| 4 | |
| 3 | |
| 2 |