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 / How can I check if a r...
Power Automate
Answered

How can I check if a row is present or not in a datatable?

(0) ShareShare
ReportReport
Posted on by

Hello Everyone.

 

I want to be able to check if a row is present in a datatable and, if it isn't, do something.

 

I use IF MyDataTable[1][0] <> 'Null' (I also tried the Is Empty option), but it doesn't seem to work and gives an 'Index is out of range' error if the row doesn't exist and the flow stops.

 

How can I check if data exists in MyDataTable[1][0] exists or not and then do something?

 

Thank you for any help.

I have the same question (0)
  • Verified answer
    Kaif_Siddique Profile Picture
    2,108 Super User 2024 Season 1 on at

    Hi @ianwuk ,

     

    Try %MyDataTable.RowsCount% or %MyDataTable.IsEmpty%

     

    Here is a sample flow:

    Kaif_Siddique_0-1674674192219.png

     

    If I have answered your question, please mark my post as Solved.

    If you like my response, please give it a Thumbs Up.

     

    Regards

    Kaif

  • CU-19081228-9 Profile Picture
    on at

    Thank you so much for your help @Kaif_Siddique 

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Vish WR Profile Picture

Vish WR 796

#2
Valantis Profile Picture

Valantis 568

#3
Haque Profile Picture

Haque 538

Last 30 days Overall leaderboard