cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
sbgoh
Post Patron
Post Patron

Count rows with a day

Hi,

 

I wish to countrows of a Sharepoint list with one day i.e. Now() 00:00:00 to Now() 23:59:59. However I am unable to get the formula correct. The field I am checking against is a sharepoint datetime field. Any advise?

 

CountRows(
Filter(
SP_LIST,
'Issue Date' >= DateTimeValue(Now(), "dd/mm/yyyy 00:00:00.fff"),
'Issue Date' <= DateTimeValue(Now(), "dd/mm/yyyy 23:59:59.fff")
)

1 ACCEPTED SOLUTION

Accepted Solutions
UdayAdhikari
Continued Contributor
Continued Contributor

@sbgoh - please give this a try. By default, DateDiff function uses "Days" to compare between 2 dates so it ignores times.

 

CountRows(
    Filter(
        SP_LIST,
        DateDiff(
            'Issue Date',
            Today()
        ) = 0
    )
)

 

Thanks

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

View solution in original post

2 REPLIES 2
UdayAdhikari
Continued Contributor
Continued Contributor

@sbgoh - please give this a try. By default, DateDiff function uses "Days" to compare between 2 dates so it ignores times.

 

CountRows(
    Filter(
        SP_LIST,
        DateDiff(
            'Issue Date',
            Today()
        ) = 0
    )
)

 

Thanks

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

It works. Thank you!

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (3,754)