Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi,
I am sorting NBA data into season and season type.
For the 2012-2013 season.
Season Type = SWITCH(TRUE(), 'Merge1'[Date] >= DATE(2012,10,5) && 'Merge1'[Date] <= DATE(2012,10,29), "Preseason", 'Merge1'[Date] >= DATE(2012,10,30) && 'Merge1'[Date] <= DATE(2013,04,19), "Regular season", 'Merge1'[Date] >= DATE(2013,04,20) && 'Merge1'[Date] <= DATE(2013,06,5), "Playoffs", 'Merge1'[Date] >= DATE(2013,06,06) && 'Merge1'[Date] <= DATE(2013,06,20), "Finals", 'Merge1'[Date] >= DATE(2013,06,21) && 'Merge1'[Date] <= DATE(2013,10,4), "Offseason"
I have 8 seasons of data.
Each season has different starting dates for the preseason, regular season etc.
Would I have to copy and alter this code for each of the 8 seasons .
Or is there an alternative?
Thanks in advance
Solved! Go to Solution.
Hi @Anonymous,
Would I have to copy and alter this code for each of the 8 seasons .
Or is there an alternative?
I think you may have to copy and alter this code for each season data.
Regards,
Yuliana Gu
Hi @Anonymous,
Would I have to copy and alter this code for each of the 8 seasons .
Or is there an alternative?
I think you may have to copy and alter this code for each season data.
Regards,
Yuliana Gu
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 40 | |
| 37 | |
| 35 | |
| 34 | |
| 27 |
| User | Count |
|---|---|
| 136 | |
| 99 | |
| 73 | |
| 66 | |
| 65 |