Skip to main content

Power BI

New

Update Dataset using Power BI REST API

Vote (62) Share
Minsuk Kang's profile image

Minsuk Kang on 06 Aug 2016 23:11:00

It's good to have Power BI REST API for creating Datasets.
It'd be really good to be able to change Datasets schema using Power BI REST API. Otherwise, it's impossible to make changes (i.e. relationships) on existing Dataset which all reports are dependent on.

Comments (7)
Minsuk Kang's profile image Profile Picture

8d46d888 6591-4ff8-98fe-1857dcfd11a0 on 05 Jul 2020 23:36:57

RE: Update Dataset using Power BI REST API

Yes, adding new tables, relationships, and measures is vital to being able to maintain datasets programmatically!

I'm building a multitenant IoT solution that will cause all kinds of headaches for customers if I can't make additive changes to existing datasets.

Minsuk Kang's profile image Profile Picture

91d4a03a cfca-48b6-962e-4c29233d10c6 on 05 Jul 2020 23:35:22

RE: Update Dataset using Power BI REST API

To clarify, we're after the ability to add new Tables to existing datasets. The existing api allows us to change the schema of existing tables, it just doesn't seem to support adding new ones.

Minsuk Kang's profile image Profile Picture

143a82d6 8300-4e54-b40c-40cfda68a89d on 05 Jul 2020 23:19:02

RE: Update Dataset using Power BI REST API

why is this not a priority / has it not been addressed for nearly 2 years?

not having this completely destroys efficiency in using the powerbi api, and will drive away users.

note that below answers do not address the issue of changing Table Names, or adding / removing Tables.

Minsuk Kang's profile image Profile Picture

fcc8e311 0719-47d2-977b-764c5e07c279 on 05 Jul 2020 22:46:29

RE: Update Dataset using Power BI REST API

how can i update my relationship schema in powerbi api?

Minsuk Kang's profile image Profile Picture

e1d354af 8dbd-4164-9e41-7ccbbbfc88cd on 05 Jul 2020 22:41:58

RE: Update Dataset using Power BI REST API

Also need to add/remove table from an dataset

Minsuk Kang's profile image Profile Picture

e6d02de5 cc6f-46b2-835c-3c1759141151 on 05 Jul 2020 22:29:59

RE: Update Dataset using Power BI REST API

Adjust your json table file to meet the requirements of your changed schema and then do a PUT to the table via the API. I've done this a few times now. Seems to work fine.

Minsuk Kang's profile image Profile Picture

c39caa1e 20c4-4f7c-a914-da85ccb2e141 on 05 Jul 2020 22:28:07

RE: Update Dataset using Power BI REST API

Apparently according to Power BI documentation, you cannot update dataset which comprises your multiple tables.

However you can update their existing schema using following API:

http://docs.powerbi.apiary.io/#reference/datasets/table/update-an-existing-tables-schema