cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
pmehhra
New Member

Submit Form Unique Entry per day in Flows

Hi, I am new to Power Automate and have a query for all good Samaritans here. I have created a form and My requirement is it should collect only 1 Entry from each user every day . i created a recurring flow to run daily that will send mail to all users to fill the form. How do i restrict 1 entry per day . If i restrict entry in forms, it doesn't allow user to enter even the second day. Thanks in Advance for help.

3 REPLIES 3
efialttes
Super User III
Super User III

Hi!

So you want to allow everybody to fill the form, but you want to grab only the first response, right?

One possible approach is to store the first response in an external repository, like CDS, Sharepoint list or excel table.

The record in the external repository should contain the date and all relevand details you need.

So whenever you receive a new response, you check first if your external repository already have a record whose date is today, if not store current response, if yes just skip it.

You can even send an email to the responder to confirm if its answer was the first received or not

Hope this helps



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Hi 

Yes you are right that this is what i am stuck at. But unable to find the right condition to put.

My data is going to share point and excel both.  Please help in which way i can put a conditionflow.JPG

Hi again!

Do you store every single response in the excel table? Also in the Sharepoint List? Also add a column date in both cases?

So, assuming you are registering each response in both Sharepoint List en Excel Table, what I miss is a 'List rows present in a table' or 'Get items' with an ODATA Filter to restrict the query to elements stored today.

 

Let's assume you add a SP 'Get items' to read nr of element in your list.

I would suggest to assign the following ODATA Expression to 'Filter query' input

 

Created ge '20200601'

 

Once executed, you can count the number of elements from the response, if more than zero, it means your current survey response is the first one. This can be achieved by means of a Condition action block, new assign the following WDL expression to the left part of your condition rule

 

empty(body('Get_items')?['value'])

 

NExt, assign the following WDL expression to the right part of your condition rule:

 

true

 

 Select the operator: is equal to

 

Now, if your flow is reexecuted today, it will take the 'true' (yes) branch if the response being processed is the first one registered today, it will take the 'false' (no) branch if not the first one registered today.

 

Once you test the flow works as expected, just need to remove 20200601 from ODATA filter expression, and add the following WDL expression instead:

 

utcNow('yyyy-MM-dd')

 

 

 DEtails on how to design ODATA Filter to check dates here:

https://powerusers.microsoft.com/t5/Building-Flows/Filter-items-with-query-on-today-error/td-p/13572...

 

Hope this makes sense



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Helpful resources

Announcements
MPA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

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.

PowerPlatform 768x460.png

Microsoft Learn

Check out our new Discover Your Career Path blog post series and get all the details.

Top Solution Authors
Users online (1,513)