web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Filter by date based o...
Power Apps
Answered

Filter by date based on Sharepoint date and time column

(0) ShareShare
ReportReport
Posted on by 89

Hi all,

 

I am trying to filter a gallery by date from a date picker based on the sharepoint "date and time" column. The column has both date and time info. (e.g. 1/1/2022 8:15 pm). But it seems the filter doesn't recognize the date only info from the date and time column.

 

This is my current formula.

Filter (Datasource, SPDateTimeColumn = datepicker.SelectedDate)

 

Anyway to achieve it?

 

Thank you for your help and support!

Eliot

Categories:
I have the same question (0)
  • Verified answer
    EddieE Profile Picture
    4,641 Moderator on at

    @mseliot 

    Date/Time values are decimals and Date values are integers and this would be why your filter isn't working correctly.

     

    You could try this

    // Set date variables to workaround delegation
    Set( vToday, datepicker.SelectedDate);
    Set( vTomorrow, DateAdd(datepicker.SelectedDate, 1, Days)
    
    // Filter
    Filter(Datasource, SPDateTimeColumn >= vToday && SPDateTimeColumn < vTomorrow)
    
    

     

    Or, you could just add a Date only column and save all the fuss.

  • mseliot Profile Picture
    89 on at

    Thank you Eddie! I simply made the Date only column and date/Time column separately to save all  the fuss 🙂

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 977

#2
Valantis Profile Picture

Valantis 664

#3
11manish Profile Picture

11manish 530

Last 30 days Overall leaderboard