cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
gardnerlhwrc
Helper II
Helper II

Filter Query help

Hi All, 

 

hope this is a really quick one. So im trying to set up a filter on my data. 

 

Summary if the due date / expiry date is 3 days from today and today is Friday - Great. but hitting an error..

I'm new to this so sure its just the way I set it up..I know the first half works because I use that in another flow so its having an issue with the 'And today is Friday part'

 

PermiteEndDate eq '@{addDays(utcNow(),3,'yyyy-MM-dd')}' and '@{dayOfWeek(utcNow())}' eq 5

 

gardnerlhwrc_0-1647001001452.png

 

Thanks L

 

1 ACCEPTED SOLUTION

Accepted Solutions
gardnerlhwrc
Helper II
Helper II

Stand down all I worked it out. 

 

Couldn't use the dayOfWeek(utcNow()) in the Filter query had to use it as a control. 

 

like so

 

gardnerlhwrc_0-1647009562335.png

 

View solution in original post

3 REPLIES 3
shoog
Super User
Super User

Removing the quotes from the dayOfWeek part should be enough to make it work:

PermiteEndDate eq '@{addDays(utcNow(),3,'yyyy-MM-dd')}' and @{dayOfWeek(utcNow())} eq 5

 

gardnerlhwrc
Helper II
Helper II

I didn't think I was making it hard but its still kicking an error.

 

gardnerlhwrc_0-1647004380156.png

The query is not valid.
clientRequestId: 525d1cc5-2003-433e-ac22-cea186968c8d
serviceRequestId: 525d1cc5-2003-433e-ac22-cea186968c8d

 

Expression - PermiteEndDate eq '@{addDays(utcNow(),3,'yyyy-MM-dd')}' and @{dayOfWeek(utcNow())} eq 5 

 

gardnerlhwrc
Helper II
Helper II

Stand down all I worked it out. 

 

Couldn't use the dayOfWeek(utcNow()) in the Filter query had to use it as a control. 

 

like so

 

gardnerlhwrc_0-1647009562335.png

 

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

New Ideas Forum MPA.jpg

A new place to submit your Ideas for Power Automate

Announcing a new way to share your feedback with the Power Automate Team.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

MPA Licensing.jpg

Ask your licensing questions at the Power Automate AMA!

Join Priya Kodukula and the licensing team, super users and MVPs to find answers to your questions on Power Automate licensing.

Users online (5,090)