Forum Discussion

alex2811's avatar
alex2811
Frequent Visitor
6 years ago
Solved

Does PIVOT break query folding?

Hi everyone,

 

I am currently redesigning some of my datasets in order to finetune their perfomance.

 

One thing I want to achieve is to push most of the heavy lifting back to the source (in my case it is a MS SQL Server) using query folding.

I noticed that as soon as I pivot (not: unpivot) a column, query folding seems to stop ("view native query" is no longer available for that applied step).

 

Can anyone tell me why this happens? According to microsoft, PIVOT should not break query folding since it has a corresponding function in SQL as far as I understand this article: (not a SQL pro, though ...)

 

https://docs.microsoft.com/en-us/power-query/power-query-folding#transformations-that-can-achieve-folding

 

Thanks!

Alex

  • Hi alex2811 , 

    I test this in my environment(I use sql database), which works well

     Not sure whether this is related to data source(check whether is Relational data source ).

    Best Regards,
    Zoe Zhi

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

     

1 Reply

  • dax's avatar
    dax
    Community Support

    Hi alex2811 , 

    I test this in my environment(I use sql database), which works well

     Not sure whether this is related to data source(check whether is Relational data source ).

    Best Regards,
    Zoe Zhi

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.