Reply
This is an open group. Sign in and click the "Join Group" button to become a group member and start posting.
Regular Visitor
Posts: 48
Registered: ‎04-08-2016
Deleting with Power BI REST API

Is there a way to delete a specific row with Power BI REST API? It seems that you are just able to delete the whole rows in the table. But I need a way to delete a specific row or update a specific row. Is that possible?

Frequent Visitor
Posts: 4
Registered: ‎08-23-2016
Re: Deleting with Power BI REST API
I don't think at the present moment such a capability is there in Power BI.
Regular Visitor
Posts: 24
Registered: ‎09-01-2016
Re: Deleting with Power BI REST API

Do you wish to delete a specific row in the power BI desktop. If so, then there is a work around. 

1. Choose the row that you wish to delete.

2. click remove rows dropdown option.

3. select remove Alternate rows.

4. In 1st row to remove, enter the row number of the particular row you wish to delete.

5. In number of rows to remove enter one

6. In numer of rows to keep, enter the numer of rows in your sheet.

 

Highlighted
Regular Visitor
Posts: 48
Registered: ‎04-08-2016
Re: Deleting with Power BI REST API
[ Edited ]

@Sagarkansal

No I don't want to delete a row in Power BI Desktop. I want to delete a row in my dataset in Power BI Service and that via Power BI REST API.

Member
Posts: 203
Registered: ‎05-09-2016
Re: Deleting with Power BI REST API

I don't know any way to achieve this goal. Power BI isn't a OLTP System, the data is fully stored in one single file. So you must use a full load without the specific row.

Regular Visitor
Posts: 48
Registered: ‎04-08-2016
Re: Deleting with Power BI REST API

My final goal is to update rows in the dataset, so I wanted to delete the specific row and insert the new one again due to the fact that Power BI REST API does not have an UPDATE command.

On stackoverflow I received this answer: http://stackoverflow.com/questions/39407924/real-time-dashboards-in-power-bi

Has somebody an idea how to accomplish this? Is that possible?

Member
Posts: 203
Registered: ‎05-09-2016
Re: Deleting with Power BI REST API
Can you please describe your scenario?
In my opinion you have only the option to add data, eg by real time data or delete the whole dataset. But this is already described at the provided link.

Power Bi stores all data in one file at the azure datalake. If you want to delete or update a specific row, you need an engine with a index. This is the reason why you don't accomplish this task.
Regular Visitor
Posts: 48
Registered: ‎04-08-2016
Re: Deleting with Power BI REST API
[ Edited ]

@philipplenz

The scenario is this:

We have a table in our datasource which contains the revenue and profit margin of different customers. For every customer and every year there is just one row. If a customer buys something new, the record of the customer with that year is updated.

Now I want to show that in Power BI dashboards but with real time data, so that the data in Power BI dashboards is updated as soon as a customer makes a transaction. For that I have to update the table in the dataset in Power BI Service. But Power BI REST API does not support an UPDATE command for existing rows.

This is the intent of my question. If Power BI REST API would offer a DELETE command for a specific row in the dataset, that could be a solution too.

I have got this answer in stackoverflow. But I don't think it works and how should be implemented.

Member
Posts: 203
Registered: ‎05-09-2016
Re: Deleting with Power BI REST API

Okay, I think you need a continued fact based table. In this scenario you push all updates as a new row. You can decide if you push the difference in the dataset (beware of the limit, if the limit of the space is reached, the first rows are kost...), so you can make only a sum of all the data, or you push a update row if anything changed for a customer. In this way you must calculate the last entry for the customer. But if you have a date key or a identity key, you can use a MAX() function to identify the last entry/row. If I can decide, I would use the second option.

Regular Visitor
Posts: 48
Registered: ‎04-08-2016
Re: Deleting with Power BI REST API

@philipplenz

The problem with the second one is that the table will expand very quickly. For every update I will have at least one new row. That will also be a performance problem. Due to the fact that our customer has a datatable with about 500.000 rows and many transactions, I can imagine that after a week I will have about 10 Mio records. So that will probably not work.

Maybe the first one will be the only solution.