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.
I'm trying to compare the current date against a column that is formatted as a datetime column in the source PBI dataset. I've re-set the Format from a datetime format to just yyyy-MM-dd in the report:
Since none of the sample data are equivalent to the current date, I just used a dummy date (Aug 27) to check if it works:
'Project'[X_DATE_CLOSED] = DATEVALUE("2024-08-27")
However, I am not getting the correct result which I assume is because of X_DATE_CLOSED being a datetime column:
Is there a way I can get only the date part of a datetime value? FORMAT() doesn't work in this case since it is a live connection.
Solved! Go to Solution.
Using DATEVALUE() on the datetime column seems to have gotten me the correct output.
Column = DATEVALUE('Project'[X_DATE_CLOSED]) = DATEVALUE("2024-08-27")
Using DATEVALUE() on the datetime column seems to have gotten me the correct output.
Column = DATEVALUE('Project'[X_DATE_CLOSED]) = DATEVALUE("2024-08-27")
User | Count |
---|---|
73 | |
72 | |
39 | |
25 | |
23 |
User | Count |
---|---|
96 | |
93 | |
50 | |
43 | |
42 |