Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

compare today date equal to another column date

How to compare (today date +1 equal to RequestClosedDate ) both are same return distinct count of Ticketno else 0

 

Capture.PNG

 i have tried 

 

Ticket-Closed-oneday =
var _DAY = DAY(MAX('Table'[RequestClosedDate]))
var _MONTH = MONTH(MAX('Table'[RequestClosedDate]))
var _YEAR = YEAR(MAX('Table'[RequestClosedDate]))

RETURN

CALCULATE(DISTINCTCOUNT('Table'[Ticketno]), FILTER('Table',DAY(TODAY()+1) = _DAY && MONTH(TODAY()) = _MONTH && YEAR(TODAY()) = _YEAR))
 
it's not working 
 

Could you help with me these questions?

Thankful

Rajesh

 

3 REPLIES 3
Mariusz
Community Champion
Community Champion

Hi @Anonymous 

 

Try this 

Ticket-Closed-oneday = 
VAR __tomorrow = TODAY() +1
RETURN 
    CALCULATE(
        DISTINCTCOUNT( 'Table'[Ticketno] ), 
        'Table'[RequestClosedDate] = __tomorrow
    )

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
LinkedIn

 

Anonymous
Not applicable

Hi @Mariusz  @amitchandak 

 

above you mentioned measures not working, its return blank value

 

suppose if i'm using column

 

Ticket-closed-oneday = IF ( TODAY ()+1 = DATE ( YEAR ( Taxone_SP1[RequestClosedDate]), MONTH ( Taxone_SP1[RequestClosedDate] ), DAY ( Taxone_SP1[RequestClosedDate] ) ),
Calculate(DISTINCTCOUNT(Taxone_SP1[Ticketno])),0)
 
it's showing duplicate ticket also,  but i need unique ticket ID
 
Thanks
Rajesh
amitchandak
Super User
Super User

@Anonymous , try like

CALCULATE(DISTINCTCOUNT('Table'[Ticketno]), FILTER('Table','Table'[RequestClosedDate] = today()+1))

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors