web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / I can't get my conditi...
Power Automate
Unanswered

I can't get my condition to check if my SQL entries are present on a sharepoint list, and if they're not then create item(SP)

(0) ShareShare
ReportReport
Posted on by

Hello

 

My Flow looks like this:

Manually trigger -> Get rows(SQL database) ->Apply to Each wrapper -> Get items(SP) -> Condition length(outputs('Get_items')?['body/value']) is greater or equal to 1 -> if true -> nothing -> if false -> Create item(SP)

 

  1. Get Rows (V2) - is connected

     

  2. Apply to each - gets the body/value from Dynamic content(Get Rows/SQL)

     

  3. Get items - connected to the sharepoint list

     

  4. Condition - length(outputs('Get_items')?['body/value']) is greater or equal to 1

     

  5. if false - create item

     

  6. if true - nothing

 

What my flow should do is to:

Get rows from my SQL database and check if the values in the database match the ones in my SP list and if not then take newest items and create them in SP.

 

 

It's pulling data from a SQL server, the database has 14 entries and if i run the flow, all 14 entries gets created in my SP List.

For the test, i then create one new entry, so there are now 15, i run the flow and it works in the way that it's not creating duplicates, so seems like my condition works, it shows in the flow that it found 15 entries but my newest entry is not created in SP

 

PA_MyFlow.PNG

 

Image is of the raw inputs from the database, the one with ID 52 is my test entry.

PA_MyData.PNG

It returns "True" in the condition so the action to create item is "skipped"

 

Everywhere i've article block or anything related to my issue, i'm told the expression length(body('Get_items')?['value']) is greater or equal to 1 is how i can solve my problem, an i feel like i'm close, i just can't get it to work correctly here in the end.

 

hope someone is able to help me

Categories:

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Automate

#1
Mohsin Ali Profile Picture

Mohsin Ali 425

#2
11manish Profile Picture

11manish 323 Super User 2026 Season 2

#3
M Bilal Khan Profile Picture

M Bilal Khan 274

Last 30 days Overall leaderboard