Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Data refresh slower over time SQL server

Hi all!   I am experiencing a bit of a weird issue, and I wonder if others have run into it. I have a dataset of about 1.4M rows on an SQL server DB.   My powerquery merges this data with another...
  • Anonymous's avatar
    Anonymous
    6 years ago

    Hey Parry!

     

    The reason I'm using merge instead of a relation, is that I do not want all data from the second table in my model. (And the first table determines what I need from the second) The second table is very big, and I only need a small part of the data. I don't want my file size to explode :). Unfortunately this is not a transactional system that I can just apply a star schema to 😞

     

    Anyway, I checked, and the query folding broke after a "change type" step. I moved that "change type" to the end, and now the folding survives the merge. It does have an effect on the loading though. It now starts out slow, and then suddenly becomes very fast at the end. By patiently staring at my screen for theduration of the refresh, I found that it sped up right after running out of rows to merge with. So the speed difference is caused by the merge. The part where it has things to merge will be slow, the part where it does not (where the left join joins with nothing) will be fast.

     

    It still seems faster and more space efficient to merge here than to use a relationship, very counter-intuitive....

     

    Thanks anyway, your mention of the query folding did help me through the process 🙂

     

    Jaap