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 / how to check wether sq...
Power Automate
Answered

how to check wether sql table has no rows in flow

(0) ShareShare
ReportReport
Posted on by 150

i have sharepoint list which i want to move from sharepoint to azure sql table , and want to check first wether sql table is empty or not

Categories:
I have the same question (0)
  • yashag2255 Profile Picture
    24,769 Super User 2024 Season 1 on at

    Hi @Tejaswini1234 

     

    You can execute a query -> Select * from tableName and then this will result in  a list of items. You can check the length of this list and if it is 0 (empty DB) then configure the next actions of the flow. 

     

    Hope this Helps!

     

    If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

  • v-bacao-msft Profile Picture
    on at

    Hi @Tejaswini1234 ,

     

    Take Sql server as an example to show how to determine whether sql table is empty.

    Azure sql will return value, return all rows as an array, you could put value in the array variable.

    Then use length() function to determine if the array variable is empty. If the result is equal to 0, the table is empty.

    Like:

    55.PNG

    Hope it helps.

     

    Best Regards,

  • Tejaswini1234 Profile Picture
    150 on at

    How to insert ,update and delete record  in sql table as if it performend in sharepoint  list  using flowio5.pngio4.pngio3.pngio2.pngio1.png.

  • Tejaswini1234 Profile Picture
    150 on at

    io1.pngio2.pngio3.pngio4.pngio5.png

  • Verified answer
    v-bacao-msft Profile Picture
    on at

    Hi @Tejaswini1234 ,

     

    Please check this thread and see if it helps:

    https://powerusers.microsoft.com/t5/General-Flow-Discussion/how-to-do-modification-insertion-and-deletion-in-SQL-table-if-it/m-p/315480

     

    Best Regards,

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 525 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 324 Moderator

#3
abm abm Profile Picture

abm abm 232 Most Valuable Professional

Last 30 days Overall leaderboard