Hello all
I have been asked to create a system where by when user fills in the ms form it will either update a row or add a row depending on the date question
So goes like this
User ms form inputs answers to 2 questions
What is the date?
What is the Meter reading?
Then once submitted it will go to add a new row on excel online or if the date is the same update the row
I have tried but get this error
Flow
When response is submitted
Get response details
Get all rows in excel table
Filter array
Excel 'what is the date' is equal to 'string(ms forms response what is the date')
Condition
Empty (arraybody) is true
If yes add a row
If no update a row
Been driving me crazy
@Anonymous
This is not actually an error , your flow looks correct this means that the condition is evaluating to true so the other branch is not executed.
hello
thanks for the response
so the flow adds a row just fine the problem is just keeps adding the row instead of updating the row
i have noted that my array input and output looks off
please see pictures its driving me crazy
here is my flow in full
here is flow
filter array
item()?[whatis the date?] is equal to string(outputs('Get_response_details')?['body/r3e3ed22d1fdc4815ab674f3a4e9cfe2b'])
condition
empty (body('Filter_array')) is equal to True
@Anonymous
The issue must be in how the date value from excel is formatted against the date field that you get from the form response details.
i think you may be onto somthing here as i just noticed my output of flow is
and the excel date format is
its taking the 0 out in excel but i dont know how to format this any ideas?
flow output is 2022-0202
excel table is 2/2/2022
cant seem to find a way of changing this so its the same
So found out that if you change the formate on excel to text its all works
@Anonymous
Can you please show what is the expression you are using here?
Thanks
User | Count |
---|---|
88 | |
39 | |
23 | |
20 | |
16 |
User | Count |
---|---|
129 | |
50 | |
48 | |
35 | |
26 |