cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper IV
Helper IV

Filter Gallery by date equal or greater than now

Hi I have a SharePoint Calendar with a column called Start Time, and I'd like to filter my gallery items to only events where the start date is equal to or greater than now. 

 

I tried with the following formula on my gallery's items property, but nothing is displaying so I must have something wrong with it. 

 

 

SortByColumns(Filter('Change Management Calendar', 'Start Time' >= Now()), "Created", Descending)

 

 

F_Quint_0-1605819914857.png

 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Super User III
Super User III

Hi @F_Quint ,

You have a Delegation warning on this as Date queries are not Delegable, However if what you are after is in the newest records, try this

With(
   {
      wCalendar:
      Sort(
         'Change Management Calendar',
         ID,
         Descending
      )
   },
   SortByColumns(
      Filter(
         wCalendar,
         'Start Time' >= Now()
      ),
      "Created",
      Descending
   )
)

You actually should not need the sort as the data sample will already be sorted this way.

 

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

6 REPLIES 6
Highlighted
Super User III
Super User III

Hi @F_Quint ,

You have a Delegation warning on this as Date queries are not Delegable, However if what you are after is in the newest records, try this

With(
   {
      wCalendar:
      Sort(
         'Change Management Calendar',
         ID,
         Descending
      )
   },
   SortByColumns(
      Filter(
         wCalendar,
         'Start Time' >= Now()
      ),
      "Created",
      Descending
   )
)

You actually should not need the sort as the data sample will already be sorted this way.

 

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

Highlighted

Hi @WarrenBelz  yes, I'm after the newest records. I tried the formula you kindly provided but it did not work. 

 

F_Quint_0-1605821053464.png

 

Highlighted

@F_Quint ,

Sorry typing error now corrected - colon: needed instead of comma,

 

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.

Highlighted

Thanks again @WarrenBelz . Looks like the formula is incomplete. 

I tinker around with it and see if I can get it working. 

 

F_Quint_0-1605833762215.png

 

 

Highlighted

@F_Quint ,

Having a bad day on a small screen - it should work now.

 

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.

Highlighted

@WarrenBelz  it sure does. Thank you so much for your time and help!!!

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Community Highlights

Community Highlights

Check out the Power Platform Community Highlights

Top Solution Authors
Top Kudoed Authors
Users online (8,100)