Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in BI by (11.1k points)

I want to create a code which compares the date in Power Bi DAX and I had a problem with the code which I created and it was not working 

Total Open Issues = 
--------------------
--basic info
VAR SELECTEDDATE =
    DATEVALUE(SELECTEDVALUE(Calender[FullDateAlternateKey].[Date]))
--------------------
--FIND the relvent data
VAR rlvttable =
    calculatetable(
    Tracker,
    Tracker[Catagory]="ISSUE",
    DATEVALUE(Tracker[ClosedDate])>SELECTEDDATE
       ||Tracker[ClosedDate]=""
    )
--------------------
--Results
Return
    countrows(rlvttable)

How can I correct this? 

1 Answer

0 votes
by (22.5k points)

use the following dax equation

Tracker[ClosedDate]>SELECTEDDATE
   &&Tracker[ClosedDate]=""

Want to learn more about Power BI? Check out today: Power BI course   

Related questions

0 votes
1 answer
asked Dec 27, 2020 in BI by Chris (11.1k points)
0 votes
1 answer
0 votes
1 answer
asked Nov 4, 2020 in BI by Sudhir_1997 (55.6k points)
0 votes
1 answer
0 votes
1 answer

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...