Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Answered

check if excel file is empty

(0) ShareShare
ReportReport
Posted on by

Hello community, I got a problem while creating a flow to check whether excel files which got imported in to sharepoint list are empty for not. My requirement is that 2 or more files could be import into SharePoint site at the same time. For the trigger,I use when a file is created (properties only)

deerzzxdell_0-1708588292106.png

deerzzxdell_2-1708588392846.png

deerzzxdell_1-1708588348620.png

 

And I got an error like this after trying to import an empty excel file,

deerzzxdell_3-1708588621274.png

 

I assume this means the flow can't find table name because it is empty. 

  • Verified answer
    v-jefferni Profile Picture
    on at
    Re: check if excel file is empty

    Hi @deerzzxdell ,

     

    According to the error, you are correct. In flow run history, you can check the output of Get tables action and see the result. To check in real run time if the excel is empty, you can use a condition control below the Get tables action:

    vjefferni_0-1708590581420.png

     

    Best regards,

  • Verified answer
    ManishSolanki Profile Picture
    15,085 Super User 2025 Season 1 on at
    Re: check if excel file is empty

    Hi @deerzzxdell 

     

    You could check the length of value object returned by "Get tables" action to know if table exists or not. 

    ManishSolanki_0-1708590309055.png

    You need to write an expression to get the length of an object array:

    length(outputs('Get_tables')?['body/value'])

     

    If table exists, then you can add subsequent actions in the "Yes" block.

     

     

    If this helps & solves your problem, please remember to give a 👍 and accept my solution as it will help others in the future.

     

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

Michael Gernaey – Community Spotlight

We are honored to recognize Michael Gernaey as our June 2025 Community…

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 566 Super User 2025 Season 1

#2
David_MA Profile Picture

David_MA 516 Super User 2025 Season 1

#3
stampcoin Profile Picture

stampcoin 492