Forum Discussion

ntimmerman's avatar
ntimmerman
Helper I
1 year ago
Solved

Slow Update Query on Dimension table with only 10 rows

Hi Community,   Can anyone explain to me why this very simple update query is taking 30s on average? I only have 10 rows in that table so I don't understand why this query takes so extremely long:...
  • ntimmerman's avatar
    ntimmerman
    1 year ago

    Hi v-dineshya ,

     

    Thank you for your prompt response and all the background information.

    In the end, I conducted further experimentation, and it appears that the GETUTCDATE() function call in the update statement significantly slows it down.

    So, I've now introduced a variable to store the current UTC date, and then I'm updating all records based on that variable instead. This makes the query a lot faster