Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
V55
Helper I
Helper I

How does List.Generate work? Will it consume memory for intermediate table data?

Hi,

 

I am trying to fetch data from Log Analytics from powerBI using Log analytics RestAPI.

 

The API has limitation of 500000 rows per query. 

And hence I am thinking of handling large dataset at powerBI by calling multiple RestAPI (with different timerange).

 

I want to make this dynamic and hence I created function (which functionality code and call Rest API on Log analytics workspace).
Then I have a loop which basically calls this function iteratively for different time range and finally append the data.

 

let 
 
list1 = List.Generate(()=>[Counter=90, table2 = null],
each [Counter] >= 0,
each [table2 = PIFunc([Counter], [Counter]-30),Counter=[Counter]-30],
each _[table2]), // skip first null value finalList = List.Skip(list1), Result = Table.FromList(finalList, Splitter.SplitByNothing(), null, null), #"Expanded Column1" = Table.ExpandTableColumn(Result, "Column1", {"BackupItemUniqueId", "ProtectedContainerUniqueIdData", "AsOnDateTime"}, {"BackupItemUniqueId", "ProtectedContainerUniqueIdData", "AsOnDateTime"}) in #"Expanded Column1"

In the above code, it calls the function PIFunc for different time range (eg - 90 to 60 days, 60 to 30 days.. ).

Like PIFunc(90,60), PIFunc(60,30), PIFunc(30, 0).

 

Finally the table data will be in the list and then table is generated.

 

 

My objective is I would like to avoid any heavy operation (in terms of memory due to 1GB dataset limitation) performed at powerBI. That's why I am using LA to do all summarization and aggregation at LA.

I would like to know if it leads to high memory consumption or not ? Does it depend on intermediate table data or not?

 

If so, what is the right way to write some sort of loop to fetch small datasets iteratively and then combine data at powerBI in a single table?

 

 

1 ACCEPTED SOLUTION
v-yuezhe-msft
Employee
Employee

@V55 ,

>>My objective is I would like to avoid any heavy operation (in terms of memory due to 1GB dataset limitation) performed at powerBI

 

There is no data volume limitation for a load for either DirectQuery or Import. We will meet the limitation for dataset when we publish a pbix file over 1GB to Power BI Service.

 

When Power Query run the above query, it will actually takes more memory, but after the data imported into dataset, Power Query will release this part of memory. The memory used by Power Query will also not affect the size of dataset.

 

Generally, to make a small pbix file and improve performance in Power BI report, please follow the guide in this article to load data and optimize report.

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-yuezhe-msft
Employee
Employee

@V55 ,

>>My objective is I would like to avoid any heavy operation (in terms of memory due to 1GB dataset limitation) performed at powerBI

 

There is no data volume limitation for a load for either DirectQuery or Import. We will meet the limitation for dataset when we publish a pbix file over 1GB to Power BI Service.

 

When Power Query run the above query, it will actually takes more memory, but after the data imported into dataset, Power Query will release this part of memory. The memory used by Power Query will also not affect the size of dataset.

 

Generally, to make a small pbix file and improve performance in Power BI report, please follow the guide in this article to load data and optimize report.

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors