cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Adding a row to excel from SharePoint List if a column contains a certain value

Hi all, 

I've set up a flow to add a new row in an excel when someone creates a new item in a list but I only want it to do this if one of the columns contains a certain value. The list has a drop down option of 5 values and is titled 'Group', I'm just unsure how to write the expression that filters out the other values to only get the one I need. 

Any help would be much appreciated! 

6 REPLIES 6
Highlighted
Dual Super User III
Dual Super User III

Re: Adding a row to excel from SharePoint List if a column contains a certain value

Hi!

How is the column defined in Sharepoint? ¿Choice? ¿Multichoice?

Assuming its internal name is 'Group' and it is of type Choice I would try with the following expression

 

triggerBody()?['Group']?['Value']

 

 

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!



Highlighted
Frequent Visitor

Re: Adding a row to excel from SharePoint List if a column contains a certain value

Hi!

Yes, it's a choice (drop down to be precise 🙂 ) I'll try that! The text choice is quite long, so for the value I'll just type it in as it appears with _ for the spaces?

Highlighted
Dual Super User III
Dual Super User III

Re: Adding a row to excel from SharePoint List if a column contains a certain value


The text choice is quite long, so for the value I'll just type it in as it appears with _ for the spaces?

You mean the column value? If I were you I would select column value from the dynamic content menu, if you do so no need to type.

But... if you decide to type, you should take into account:

-You need to figure out what the internal sharepoint columnname is. So if you used special characters as spaces etc. the internal name differs from the displayed one, also if you changed the column name (it would retain the old one as internal name).

-What I shared above is a expression. Please follow these steps to add expressions:

https://flow.microsoft.com/es-es/blog/use-expressions-in-actions/

 

Hope this helps

 

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!



Highlighted
Frequent Visitor

Re: Adding a row to excel from SharePoint List if a column contains a certain value

flow1.pngflow2.png
@efialttes where would I put this? I thought I might need to do a filter function or something? There's 5 different options in Group and I only want to create a new excel line if 'Education BLANK BLANK BLANK' (example) is chosen by the user.

Highlighted
Dual Super User III
Dual Super User III

Re: Adding a row to excel from SharePoint List if a column contains a certain value

Hi!

I would add a Condition action block just in between your current two blocks.

Once added, define its condition rule, and move 'Insert row' inside the true branch

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!



Highlighted
Frequent Visitor

Re: Adding a row to excel from SharePoint List if a column contains a certain value

I'm pretty sure it's me just being daft now but I've done that and it's still not working! I don't think I'm defining the condition rule correctly? 

What's the best way to do that?

Helpful resources

Announcements
Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Upcoming Events

Experience what’s next for Power Automate

See the latest Power Automate innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Community Conference

Power Platform Community Conference

Find your favorite faces from the community presenting at the Power Platform Community Conference!

Top Solution Authors
Top Kudoed Authors
Users online (6,642)