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
AndrewSikomas
Regular Visitor

Performance Issues with Unpivot and Append Query

Hello everyone,

 

First-time, long-time...

 

I have a table that contains two Values (that would go in the Value field in a visual). I want them to be in the same column, and I can differentiate between them using another column and the attribute in that column.

 

Naturally I used Unpivot Columns. This works fine, except the refresh rate (Oracle connection) went from thousands of rows per second to TENS of rows per second. I have millions of rows, so this is not practical.

 

My next best option was to separate the table into two tables. I first duplicated my table, then prepared each resultant table accordingly, and Appended one to the other. All column names and order are identical in both tables. This too is taking FOREVER. I do not understand why that would be.

 

For Unpivot I understand why it would reduce performance. For Append though, I don't get it.

 

I then tried to do all my data prep on the table, then reference the table into a new query, Table.Buffer it, THEN Unpivot, thinking this would Unpivot as a local operation, but when I Close&Apply, the data load is from the Oracle source and is still very, very slow.

 

Any ideas?

1 ACCEPTED SOLUTION
kcantor
Community Champion
Community Champion

@AndrewSikomas 

It sounds like your query is folding at an inopportune time. Check out these two resources to see if you can tweak the query for speed.

https://www.mssqltips.com/sqlservertip/3635/query-folding-in-power-query-to-improve-performance/

https://blog.pragmaticworks.com/power-bi-checking-query-folding-with-view-native-query





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

1 REPLY 1
kcantor
Community Champion
Community Champion

@AndrewSikomas 

It sounds like your query is folding at an inopportune time. Check out these two resources to see if you can tweak the query for speed.

https://www.mssqltips.com/sqlservertip/3635/query-folding-in-power-query-to-improve-performance/

https://blog.pragmaticworks.com/power-bi-checking-query-folding-with-view-native-query





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




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