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

Advice on new flow required

Hi,

 

I'd like to build a flow that the outputs a table of columns each day, however I only want items in the table that match a few specific conditions.

 

So for example, I have status column, when the status changes to the value "not select", I want power automate to collect all the items in the last 24 hours that have changed to this status and add to a table, then the table is sent in an email each morning. 

 

So I need a reoccurring schedule flow to start, then maybe get file properties, has column changed in a condition, would this work for a start, or does the trigger need to be "when an item is modified".

 

Either way, how would I get it to look back over the past 24 hours only? Is this possible?

9 REPLIES 9
Pstork1
Dual Super User
Dual Super User

If you want to do it once a day then definitely use a recurrence trigger and a get file properties or get items.  Try to filter it with an OData query, although you may not be able to get everything filtered out using just OData.  Then use a Filter array to remove anything else that shouldn't be there.  Use a Data select to specify the exact columns you want in the table and then convert the array to HTML.  That can then be embedded in the email.



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Join me at 365 and PWR EduCon in Chicago
EduCon Chicago 2022

Thanks, what would the filter array need to look like to filter out anything that's hasn't been modified in the last 24 hours?

image.png



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Join me at 365 and PWR EduCon in Chicago
EduCon Chicago 2022

hi again - this query isnt working for me: @And(greater(item()?['Modified'],addHours(utcNow(),-24),less(item()?['Modified'],utcNow()))

 

Any idea why?

hi again - this query isnt working for me: @And(greater(item()?['Modified'],addHours(utcNow(),-24),less(item()?['Modified'],utcNow()))

 

Any idea why?

The query is case sensitive.  Its @and(.... not @And(....



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Join me at 365 and PWR EduCon in Chicago
EduCon Chicago 2022

yes I tried with lowercase - that's just my grammar correction on edge!!

What error are you getting?

 



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Join me at 365 and PWR EduCon in Chicago
EduCon Chicago 2022

Try the following.  I think the one you are using might be missing a parentheses.  This works for me.

 

@And(greater(item()?['Modified'], addHours(utcNow(), -24)),less(item()?['Modified'], utcNow()))

 



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Join me at 365 and PWR EduCon in Chicago
EduCon Chicago 2022

Helpful resources

Announcements
 WHAT’S NEXT AT MICROSOFT IGNITE 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Register for a Free Workshop.png

Register for a Free Workshop

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

September Events 2022

Check out all of these events

Attend in person or online, there are incredible conferences and events happening all throughout the month of September.

Users online (3,109)