Forum Discussion
Can we create a template app with Push Dataset?
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 done
and then takes me to the Authentication tab.
And there I only see a spinning wheel that says Loading indefinitely.
Spinning 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);
}