cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
T-Ang
New Member

Form > excel > Approve

I have a form Users are filling out when they have a request, then their responses are getting sent to an excel sheet. Within my excel sheet I have multiple sheets where I lookup information based off what the User entered into the form. 

 

I'm trying to create a flow where the user fills out the form (I have another flow where the when the response is submitted a new row gets added to excel), then an approval gets sent to the Manager. But within the email I want to provide information from the excel sheet. The issue is that all rows are getting sent to the manager every time the form gets filled out 

 

What formula can I use within "List rows present in a table" to only send 1 row for approval, basically every time the form gets filled out I want the approval being sent with the information from excel sheet as well. 

 

TAng_0-1640006239080.png

TAng_1-1640006950544.png

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
leo85
Continued Contributor
Continued Contributor

Hi @T-Ang ,

in your first message you wrote: "I have another flow where the when the response is submitted a new row gets added to excel".

Just to understand this. You have two flows. One (flow A) that writes information to the excel sheet and one (flow B), which sends an approval with the information from the excel sheet based. We are currently looking at flow B. Both start when a response is submitted for the same form, right?

If this is correct, the current setup will not work, because when the form is submitted you cannot be certain that flow A runs and finishes before flow B.

You could add a "delay" of a few minutes right after the trigger, to wait for the first flow to finish. Then you could use the "Response ID" as the key value. So you would add an additional column to your Excel table and have flow A write the "Response Id" into this column. Flow B can then identify the row by using the "Response Id" (see screenshot). But this will only work if flow B gets the information from Excel after flow A has finished. To me, this solution is not very clean, but requires the least amount of changes.

leo85_0-1640071696741.png

 

Another option would be to combine both flows into one flow. Trigger when a response is submitted. Add a row with the data to the Excel sheet. Get the row from Excel. Send the approval. (To me it is not really clear what the Excel is doing. Is this a kind of lookup? If you just add a row to Excel and afterwards you get the same information, you shouldn't need the Excel at all before send the approval.

View solution in original post

10 REPLIES 10
ScottShearer
Most Valuable Professional
Most Valuable Professional

@T-Ang 

I would first try using an OData filter query to retrieve the single row in which you are interested.  If you click on Advanced options in the List rows action, you'll see the option for Filter query.  Here is a post that shows how to use OData filters with SharePoint - Excel is very similar.

If that doesn't work for you, try using a Filter array action.

Please post here with screen shots of your Flow if you have additional questions.

 

 

 

 

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

Scott
leo85
Continued Contributor
Continued Contributor

Hi @T-Ang ,

the action "List rows present in table" retrieves all rows within a specific table. So a loop is created and an approval sent for each row.

As I understand there is only one row for each time a user fills in the form, correct?

Why are you using "List rows present in table"? You can use the action "Get a row". This will get you one specific row from the table. For this you need a key column in your table and a key (from the form) to identify the correct row.

Alternatively, you can use the "Filter" action from the "Data Operation" connector. You can filter the output from "List rows present in a table" to return only that row, which fits the filter criteria. Note: The "Filter" action returns an array, so you still need an apply to each loop even if you only return one row.

Regards,

Leo

 

--------------------------------------------------------------------------
If I have answered your question, please mark my post as a solution
If you have found my response helpful, please give it a thumbs up

Thanks so much for the idea of using "Get a row" instead. I'm using the Time submitted at the key value. But for some reason it is not working. Do you happen to know why?

 

TAng_0-1640016083762.png

TAng_1-1640016374649.png

 

 

ScottShearer
Most Valuable Professional
Most Valuable Professional

@T-Ang 

By default, when you retrieve dates/times from Excel they are returned as numbers rather than as a date.  To have a date returned, set the Date/Time format in the List rows action (under advanced) to ISO 8601.

 

 

 

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

Scott

Thanks for that note! 

 

I used "Get Row" and changed the Date Format to ISO 8601, but it's still not matching.

 

In my excel sheet anytime a row gets added it gets assigned the following number. Do you know if this is something I could use to get the row information sent out?

 

TAng_0-1640020770050.png

 

 

ScottShearer
Most Valuable Professional
Most Valuable Professional

@T-Ang 

Please post a screen shot of your Flow with the details showing.  Also, I had suggested "List rows present in a table".

 

 

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

Scott

When I use list row I get all rows on the excel form. I'm not sure what expressions to put for the filter query. 

 

Heads up - this is my first time ever using power automate and I don't have any coding skills.

TAng_0-1640023658527.png

 

When using "Get Row" I was using key column & key value for the submitted time. 

TAng_1-1640023888963.png

 

 

leo85
Continued Contributor
Continued Contributor

Hi @T-Ang ,

in your first message you wrote: "I have another flow where the when the response is submitted a new row gets added to excel".

Just to understand this. You have two flows. One (flow A) that writes information to the excel sheet and one (flow B), which sends an approval with the information from the excel sheet based. We are currently looking at flow B. Both start when a response is submitted for the same form, right?

If this is correct, the current setup will not work, because when the form is submitted you cannot be certain that flow A runs and finishes before flow B.

You could add a "delay" of a few minutes right after the trigger, to wait for the first flow to finish. Then you could use the "Response ID" as the key value. So you would add an additional column to your Excel table and have flow A write the "Response Id" into this column. Flow B can then identify the row by using the "Response Id" (see screenshot). But this will only work if flow B gets the information from Excel after flow A has finished. To me, this solution is not very clean, but requires the least amount of changes.

leo85_0-1640071696741.png

 

Another option would be to combine both flows into one flow. Trigger when a response is submitted. Add a row with the data to the Excel sheet. Get the row from Excel. Send the approval. (To me it is not really clear what the Excel is doing. Is this a kind of lookup? If you just add a row to Excel and afterwards you get the same information, you shouldn't need the Excel at all before send the approval.

v-jefferni
Community Support
Community Support

Hi @T-Ang ,

 

You can also call flow B from flow A using the HTTP request action in flow A, so after flow A is finished successfully it will call the other flow. Please refer to below video form Shane Young:

https://www.youtube.com/watch?v=umBegXooiKU&t=643s

 

Hope this helps.

 

Best regards,

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

Community Support Team _ Jeffer Ni

If this post helps, then please consider Accept it as the solution to help the other members find it.

Note that these are premium connectors. So you need to have/buy a premium license to use them.

 


You can also call flow B from flow A using the HTTP request action in flow A, so after flow A is finished successfully it will call the other flow.

 

Helpful resources

Announcements

Community will be READ ONLY July 16th, 5p PDT -July 22nd

Dear Community Members,   We'd like to let you know of an upcoming change to the community platform: starting July 16th, the platform will transition to a READ ONLY mode until July 22nd.   During this period, members will not be able to Kudo, Comment, or Reply to any posts.   On July 22nd, please be on the lookout for a message sent to the email address registered on your community profile. This email is crucial as it will contain your unique code and link to register for the new platform encompassing all of the communities.   What to Expect in the New Community: A more unified experience where all products, including Power Apps, Power Automate, Copilot Studio, and Power Pages, will be accessible from one community.Community Blogs that you can syndicate and link to for automatic updates. We appreciate your understanding and cooperation during this transition. Stay tuned for the exciting new features and a seamless community experience ahead!

Summer of Solutions | Week 4 Results | Winners will be posted on July 24th

We are excited to announce the Summer of Solutions Challenge!    This challenge is kicking off on Monday, June 17th and will run for (4) weeks.  The challenge is open to all Power Platform (Power Apps, Power Automate, Copilot Studio & Power Pages) community members. We invite you to participate in a quest to provide solutions to as many questions as you can. Answers can be provided in all the communities.    Entry Period: This Challenge will consist of four weekly Entry Periods as follows (each an “Entry Period”)   - 12:00 a.m. PT on June 17, 2024 – 11:59 p.m. PT on June 23, 2024 - 12:00 a.m. PT on June 24, 2024 – 11:59 p.m. PT on June 30, 2024 - 12:00 a.m. PT on July 1, 2024 – 11:59 p.m. PT on July 7, 2024 - 12:00 a.m. PT on July 8, 2024 – 11:59 p.m. PT on July 14, 2024   Entries will be eligible for the Entry Period in which they are received and will not carryover to subsequent weekly entry periods.  You must enter into each weekly Entry Period separately.   How to Enter: We invite you to participate in a quest to provide "Accepted Solutions" to as many questions as you can. Answers can be provided in all the communities. Users must provide a solution which can be an “Accepted Solution” in the Forums in all of the communities and there are no limits to the number of “Accepted Solutions” that a member can provide for entries in this challenge, but each entry must be substantially unique and different.    Winner Selection and Prizes: At the end of each week, we will list the top ten (10) Community users which will consist of: 5 Community Members & 5 Super Users and they will advance to the final drawing. We will post each week in the News & Announcements the top 10 Solution providers.  At the end of the challenge, we will add all of the top 10 weekly names and enter them into a random drawing.  Then we will randomly select ten (10) winners (5 Community Members & 5 Super Users) from among all eligible entrants received across all weekly Entry Periods to receive the prize listed below. If a winner declines, we will draw again at random for the next winner.  A user will only be able to win once overall. If they are drawn multiple times, another user will be drawn at random.  Individuals will be contacted before the announcement with the opportunity to claim or deny the prize.  Once all of the winners have been notified, we will post in the News & Announcements of each community with the list of winners.   Each winner will receive one (1) Pass to the Power Platform Conference in Las Vegas, Sep. 18-20, 2024 ($1800 value). NOTE: Prize is for conference attendance only and any other costs such as airfare, lodging, transportation, and food are the sole responsibility of the winner. Tickets are not transferable to any other party or to next year’s event.   ** PLEASE SEE THE ATTACHED RULES for this CHALLENGE**   Week 1 Results: Congratulations to the Week 1 qualifiers, you are being entered in the random drawing that will take place at the end of the challenge.   Community MembersNumber SolutionsSuper UsersNumber Solutions Deenuji 9 @NathanAlvares24  17 @Anil_g  7 @ManishSolanki  13 @eetuRobo  5 @David_MA  10 @VishnuReddy1997  5 @SpongYe  9JhonatanOB19932 (tie) @Nived_Nambiar  8 @maltie  2 (tie)   @PA-Noob  2 (tie)   @LukeMcG  2 (tie)   @tgut03  2 (tie)       Week 2 Results: Congratulations to the Week 2 qualifiers, you are being entered in the random drawing that will take place at the end of the challenge. Week 2: Community MembersSolutionsSuper UsersSolutionsPower Automate  @Deenuji  12@ManishSolanki 19 @Anil_g  10 @NathanAlvares24  17 @VishnuReddy1997  6 @Expiscornovus  10 @Tjan  5 @Nived_Nambiar  10 @eetuRobo  3 @SudeepGhatakNZ 8     Week 3 Results: Congratulations to the Week 3 qualifiers, you are being entered in the random drawing that will take place at the end of the challenge. Week 3:Community MembersSolutionsSuper UsersSolutionsPower Automate Deenuji32ManishSolanki55VishnuReddy199724NathanAlvares2444Anil_g22SudeepGhatakNZ40eetuRobo18Nived_Nambiar28Tjan8David_MA22   Week 4 Results: Congratulations to the Week 4 qualifiers, you are being entered in the random drawing that will take place at the end of the challenge. Week 4:Community MembersSolutionsSuper UsersSolutionsPower Automate Deenuji11FLMike31Sayan11ManishSolanki16VishnuReddy199710creativeopinion14Akshansh-Sharma3SudeepGhatakNZ7claudiovc2CFernandes5 misc2Nived_Nambiar5 Usernametwice232rzaneti5 eetuRobo2   Anil_g2   SharonS2  

Check Out | 2024 Release Wave 2 Plans for Microsoft Dynamics 365 and Microsoft Power Platform

On July 16, 2024, we published the 2024 release wave 2 plans for Microsoft Dynamics 365 and Microsoft Power Platform. These plans are a compilation of the new capabilities planned to be released between October 2024 to March 2025. This release introduces a wealth of new features designed to enhance customer understanding and improve overall user experience, showcasing our dedication to driving digital transformation for our customers and partners.    The upcoming wave is centered around utilizing advanced AI and Microsoft Copilot technologies to enhance user productivity and streamline operations across diverse business applications. These enhancements include intelligent automation, AI-powered insights, and immersive user experiences that are designed to break down barriers between data, insights, and individuals. Watch a summary of the release highlights.    Discover the latest features that empower organizations to operate more efficiently and adaptively. From AI-driven sales insights and customer service enhancements to predictive analytics in supply chain management and autonomous financial processes, the new capabilities enable businesses to proactively address challenges and capitalize on opportunities.    

Updates to Transitions in the Power Platform Communities

We're embarking on a journey to enhance your experience by transitioning to a new community platform. Our team has been diligently working to create a fresh community site, leveraging the very Dynamics 365 and Power Platform tools our community advocates for.  We started this journey with transitioning Copilot Studio forums and blogs in June. The move marks the beginning of a new chapter, and we're eager for you to be a part of it. The rest of the Power Platform product sites will be moving over this summer.   Stay tuned for more updates as we get closer to the launch. We can't wait to welcome you to our new community space, designed with you in mind. Let's connect, learn, and grow together.   Here's to new beginnings and endless possibilities!   If you have any questions, observations or concerns throughout this process please go to https://aka.ms/PPCommSupport.   To stay up to date on the latest details of this migration and other important Community updates subscribe to our News and Announcements forums: Copilot Studio, Power Apps, Power Automate, Power Pages