cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
viktorklingberg
Level: Powered On

Check dates in multiple columns

Hello,

 

We've a sharepoint list with our staff and some other information.

Our staff get qualifications with a expiry date and we've a hard time keeping track to rescheduling them for a new training.

I would like to add a date-column for each qualification and put in the expiry date and use Flow to send a email to remind us to book that particular training for the specific person.

We will need somewhere between 20 and 30 diffrent colums and probably add more columns in the future why I would like a very adaptable Flow.

 

All other Flow solutions I've seen uses several conditions to check the dates on each specific column.

Is it possible to have a flow that check all columns in one go? or does anyone have a good suggestions to solve this?

 

Thank you!

Regards,

Viktor

6 REPLIES 6
dbro
Level: Powered On

Re: Check dates in multiple columns

Hi @viktorklingberg ,

 

Couple of thoughts:

1.) could you use an out of the box alert?  For example could you create a view that shows all items where Expiry Date equals today or Date2 equals Today or Date3 equals today?  Then you can set an alert to you and your team any time a new item gets added to that view.

 

2. Using the FLOW mechanism you could use an odata filter on the get items action to show you all items where your expiry column equals today. then you could do a for each loop and send email action.  I think for this to work your email would have to be generic and link to the sharepoint item and not include the column date in the body as you wouldn't know which column to include without doing a conditional check that you're trying to avoid.

viktorklingberg
Level: Powered On

Re: Check dates in multiple columns

Hi @dbro,

Thanks for your reply!

 

1.) That could work. But I would need to set a new alert for each new column, right?

 

2.) Sounds interesting! I would want the alert maybe 30 days before the expiry date, but that's not a problem.

Can i do a odata filter on all columns? I thought i needed to choose one column to filter.. How would that code look like?

 

Thanks!

Community Support Team
Community Support Team

Re: Check dates in multiple columns

Hi @viktorklingberg ,

 

Please try to use 'and' in Filter Query to check the values of multiple date fields.

Image reference:

31.PNG

 

Best Regards,

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
viktorklingberg
Level: Powered On

Re: Check dates in multiple columns

Hello @v-bacao-msft,

Thanks for your reply.

 

That'll work. But then I'll have to edit the filter query each time we add a column in the sharepoint list.

Is there no way to filter something like this: "All columns except [created date] and [edit date] le utcNow()" ?

That way it doesn't matter what we do in the sharepoint list, the flow will always remind us.

 

Regards,

Viktor

dbro
Level: Powered On

Re: Check dates in multiple columns

@viktorklingberg ,

 

I would first try to set up a list view using or statements.  For example:

'YourDateColumn' = Today 

or

'YourDateColumn2' = Today

or

'YourDateColumn3' = Today

 

Etc, etc.  Then create an alert on your view to send you an email anytime an new item is added.  The benefit of doing it this way is you just need to edit your list view when you add or remove an item instead of your odata parameters in the flow.  You may need to create 2 different views if you have 20-30 date columns.

Community Support Team
Community Support Team

Re: Check dates in multiple columns

Hi @viktorklingberg ,

 

As far as I know, there seems to be no way to get the column in the list through Flow. I am afraid we really need to edit Filter Query when adding a new column.

This does not seem to be automated.

 

Best Regards,

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

Helpful resources

Announcements
firstImage

Microsoft Business Applications Virtual Launch Event

Watch the event on demand for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 Release Wave 2 Plan

Power Platform 2019 Release Wave 2 Plan

Features releasing from October 2019 through March 2020.

thirdimage

Flow Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Flow Community Video Gallery!

Top Kudoed Authors
Users Online
Currently online: 171 members 4,877 guests
Please welcome our newest community members: