cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Danielx64
Advocate I
Advocate I

Get SharePoint items based on 3 requirements where 1 is required before the other 2

Hi all,

 

I got a register that has 2 different date fields and an email field with other fields.

 

What I am able to do for the filter is "date1 lt '@{utcNow('yyyy-MM-dd')}' or date2 lt '@{utcNow('yyyy-MM-dd')}'".

 

What I want to do is filter out all the all the results that doesn't have anything in email field. Does anyone know how I can go about this?

 

Cheers

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @Danielx64,

 

So you want to put the 3 requirements into the Get items at the same time, but you don't know how to do it, right?

Please refer to the following syntax:

Email eq null and (Date1 lt '2020-06-01' or Date2 lt '2020-06-01')

Annotation 2020-05-11 103228.png

 

Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

4 REPLIES 4
v-litu-msft
Community Support
Community Support

Hi @Danielx64,

 

You could use this filter query:

EmailAddress eq null

Annotation 2020-05-08 155317.png

 

Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @v-litu-msft ,

 

Thank you for the suggestion. I'm not sure if I explained myself well enough but I need to filter out the items that doesn't have an email address (my flow is based on sending an email) and that date1 or date2 is less than the current date (The email being sent is to remind people that they need to update their details in our system and we have 2 different expiry dates - the expiry dates are for different things).

 

Cheers

Hi @Danielx64,

 

So you want to put the 3 requirements into the Get items at the same time, but you don't know how to do it, right?

Please refer to the following syntax:

Email eq null and (Date1 lt '2020-06-01' or Date2 lt '2020-06-01')

Annotation 2020-05-11 103228.png

 

Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Thank you so much, I wasn't even aware that I could do ( and ) and teat it like math 🙂 After putting the bits in everything worked as expected 🙂

Helpful resources

Announcements
Process Advisor

Introducing Process Advisor

Check out the new Process Advisor community forum board!

MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Users online (2,088)