Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Just need a simple calculated column
=if(MOHDEP1[FDDate]>= "03/01/23", 1,0)
This errors out. What is the proper syntax to do a simple date comparison?
=if(MOHDEP1[FDDate]>= date(2023,3,1), 1,0) works, but I would think there is a shorter way to write this code?
Same with BETWEEN. To create a calculated column to flag records between two dates, is there a better way to write:
=if(MOHDEP1[FDDate]>= date(2023,3,1) && MOHDEP1[FDDate]<= date(2023,6,30), 1,0) ?
Thanks.
Solved! Go to Solution.
Hi @domtrump
there are other few ways to that but they're no better than this one. You my use DATEVALUE or CONVERT-DATETIME but nothing I personally prettge DATE approach. No need to be frustrated I guess.
Hi @domtrump
there are other few ways to that but they're no better than this one. You my use DATEVALUE or CONVERT-DATETIME but nothing I personally prettge DATE approach. No need to be frustrated I guess.
User | Count |
---|---|
25 | |
11 | |
8 | |
6 | |
6 |
User | Count |
---|---|
27 | |
13 | |
11 | |
9 | |
6 |