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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Import data from sql s...
Power Automate
Unanswered

Import data from sql server to a sharepoint list

(0) ShareShare
ReportReport
Posted on by 4

Hello, 


I created a new flow to import data from sql server to a sharepoint list. 

 

But I have an issue because I need to add a filter in my sql request from the previous request (previous request is : get sharepoint items). From my previous request I have a field (Request number) that I need to add in the sql filter. How can I do it ? 

mimi1255_0-1649240158613.png

 

Thanks a lot. 

 

Categories:
I have the same question (0)
  • Riyaz_riz11 Profile Picture
    3,844 Super User 2025 Season 2 on at

    Hi @mimi1255 ,

    You can provide condition if it matches then do this you can use.

     

    Regards

    Ahammad Riyaz

    --------------------------------------------------------------------------------
    If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.

  • KvB1 Profile Picture
    1,596 on at

    Do you need to pull records for:

     

    each record returned from the get items action

    each unique request number returned from the get items action

    just one request number

     

    ?

  • mimi51340 Profile Picture
    4 on at

    For each item in the sharepoint list containing a request number, I need to check the sql table to see if the number exists.
    And if it exists I need to get the amount of the orders.

  • KvB1 Profile Picture
    1,596 on at

    Okay so that would be option: each unique request number returned from the get items action?

     

    After the get items action, add a select action to grab the request number.

     

    Then, add a compose action, where you union( the output of the select action with itself, to return an array with unique request numbers. This will also eliminate empty records.

     

    Then you give compose action as input for an apply to each loop, where you can use an odata filter query in the sql action, something like: SQLColumnName eq items('Apply_to_each')?['RequestNumber']

     

    On a side note, if you are working with large tables, power automate is not the greatest tool to use, since it will take a very long time to go through the flow, and you might run into throttle limits

  • mimi51340 Profile Picture
    4 on at

    Hello, 

    I do not understand the second step. 

    I created this :

    mimi1255_0-1649320939761.png

     

    But I did not understand the following step.

     

    Thanks a lot

     

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 538 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 405 Moderator

#3
abm abm Profile Picture

abm abm 252 Most Valuable Professional

Last 30 days Overall leaderboard