cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
cte_crest
Helper I
Helper I

Can we create a template app with Push Dataset?

Hi folks,

 

I am learning PowerBI and the experience has been great lately. I am thinking about one of the possible ways to fulfil my use case. I want to publish a template app on the Microsoft AppSource. Now, the app will have a sample dataset shipped with it. In all the general use cases of other apps, I see that the data in the shipped dataset is usually refreshed through native connector mechanism, i.e., through M Query. Now, is there a way that after installing the template app from the app source, user pushes the data to that data set through rest API?

 

Currently, when I loaded a pbix file in PowerBI service, and  I was not able to retrieve the data set supplied in pbix file through rest API.

9 REPLIES 9
Dutta
New Member

Hi @Teddyb ,

 

Are you saying that it is not possible to create template apps out of workspaces that have ONLY push datasets created through the API?

 

I, for example, have created a new workspace with datasets, tables and the data therein only through the REST API. Now that I want to create an app out of it, it asks me to complete all the fields with as asterix on it 

Not quite doneNot quite done

and then takes me to the Authentication tab.

 

And there I only see a spinning wheel that says Loading indefinitely.

Spinning wheelSpinning wheel

This makes it hard to zero in on the real issue. Is this a bug on the service?

 

Note that I have not used PBIX file for anything here- its all built up online. All datasets were created out of the API. And none of the tables have any data source associated with it. 

 

Any ideas whats wrong?

 

Dataset and content was created using this code,

 

 

                // create dataset and table
                Dataset shippedProductsDataSet = await this.GetDataSet(client, "ShippedProducts");
                if (shippedProductsDataSet == default(Dataset))
                {
                    var createDataSet = new CreateDatasetRequest(
                        "ShippedProducts",
                        new List<Table>
                        {
                            new Table(
                                "Product",
                                new List<Column>
                                {
                                    new Column("Id", "string"),
                                    new Column("Name", "string")
                                }));
                    shippedProductsDataSet = client.Datasets.PostDatasetInGroup(PBIWorkSpaceId, createDataSet);
                }
                shippedProductsDataSet = client.Datasets.PostDatasetInGroup(PBIWorkSpaceId, createDataSet);


                // Create sample data
                var tables = client.Datasets.GetTablesInGroup(PBIWorkSpaceId, shippedProductsDataSet.Id);
                if (!tables.Value.Any(t => t.Name == "Product" && t.Rows != null && t.Rows.Count > 0))
                {
                    var productPostRowsRequest = new PostRowsRequest(
                        new List<object>
                        {
                        new {Id = 1, Name = "A"},
                        new {Id = 2, Name = "B"},
                        new {Id = 3, Name = "C"}
                        });
                    client.Datasets.PostRowsInGroup(PBIWorkSpaceId, shippedProductsDataSet.Id, "Product", productPostRowsRequest);
                }

 

 

Teddyb
Microsoft
Microsoft

Hi, 

 

Sorry for the late reply, indeed template apps are a great way to create deployable solution and publish on AppSource but they rely on Connectors extensibility story. 

 

If you own the datasource you can apply to certify your connector which will allow the template app use the certified connector.

Maybe the datasource you are trying to connect with support OData? 

 

v-shex-msft
Community Support
Community Support

Hi @cte_crest,

I'd like to suggest you use 'power bi service' connect to get data from power bi service, it linked with your power bi account and you can access existing datasets.

If you mean get data from the root URL of power bi datasets, I'd like to suggest you take a look at azure blob storage API. (AFAIK, power bi host its dataset on azure blob storage data source)

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

@v-shex-msft 

Thanks for your reply. Actually, I want to push data to the dataset on template apps.

So, let me try to put it in a concise way, about the steps I performed:

  1. For adding data to powerBI dataset, I want to use Push mechanism through API.
  2. So, I created some tables in a data set through push api data set and corresponding reports and exported pbix file which I want different users to use as a template app. (I think this is also what will go on the app source when template app will be published.)
  3. Now, I imported the pbix file, in a new workspace where I get all my reports and data set as well. 
  4. I tried to push data to this data set using powerBI api. That's when I encountered error, indicating that this dataset doesn't support push mechanism.

So, do you think this could be solved? Or am I using it all wrong? 

HI @cte_crest,

Please double-check on Push datasets REST API limitations, it only allows on push dataset and not works on common datasets that publish form pbix file. Push Datasets 

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

@v-shex-msft 

Thanks for your information. It makes sense. 

I think I was going for an incorrect use case. 

I just had another concern. From https://docs.microsoft.com/en-us/power-bi/developer/automation/api-rest-api-limitations?redirectedfr..., it seems that the maximum rows allowed in a table for Push Dataset are 5 Million. Is there any reason for it? Is there any way to increase the capacity? At least for premium capacity?

Hi @cte_crest,

I check the official document but not found they mentioned high level license can improve the limitations of rest api. Maybe you can submit an idea for this requirement.

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

@v-shex-msft 

I am sorry, but I was not able to understand what do you mean by "high level license can improve the limitations of rest api"?

 

Does any license exist which may help with relaxation of this limit?

Hi @cte_crest,

>>I am sorry, but I was not able to understand what do you mean by "high level license can improve the limitations of rest api"?

Full feature version power bi pro and its upgrade version premium(split by their capacity).

Power BI service features by license type 

>>Does any license exist which may help with relaxation of this limit?

Unfortunately, these licenses didn't increase the limit range of rest API usage.
Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

Helpful resources

Announcements
Carousel_PBI_Wave1

2023 Release Wave 1 Plans

Power BI release plans for 2023 release wave 1 describes all new features releasing from April 2023 through September 2023.

Power BI Summit Carousel 2

Global Power BI Training

Make sure you register today for the Power BI Summit 2023. Don't miss all of the great sessions and speakers!

BizApps LATAM 2023

Business Application LATAM Summit 2023

Join the biggest FREE Business Applications Event in LATAM this February.

Power Platform Bootcamp

Global Power Platform Bootcamp

In this bootcamp we will deep-dive into Microsoft’s Power Platform stack with hands-on sessions and labs, delivered to you by experts and community leaders.