Forum Discussion
Performance with many SWITCH or IFs slow. Is there a solution with good performance?
- 4 years ago
Calculation groups may not help, the best performance can be obtained by using SWITCH but you have to pay attention to the details. See this article+video: Understanding the optimization of SWITCH - SQLBI
Calculation groups may not help, the best performance can be obtained by using SWITCH but you have to pay attention to the details. See this article+video: Understanding the optimization of SWITCH - SQLBI
Hi selimovd marcorusso,
Just proposing an alternative here that has worked pretty well in my models:
You couls use a field parameter to dynamically calculate the measure you want. This way we can skip the optimization process of SWITCH:
I hope this post helps to solve your issue and if it does consider accepting it as a solution and giving the post a thumbs up!
My LinkedIn: https://www.linkedin.com/in/n%C3%A4ttiahov-00001/