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

Community site session details

Session Id : vgKXTdnAFi0Lcmvno0Zlhj
Power Automate - Using Connectors
Answered

Use the Empty in Filter array

Like (0) ShareShare
ReportReport
Posted on 2 Oct 2019 01:42:17 by 164

Dear All,

 

I would like to filter the empty value's item to remain the item"0" that has value, but trial many expression can't achieve, please give me the help, the expression I tried:

empty(outputs('Compose_4')?['0'])
empty(body('Compose_4')?['0'])
empty(items('0'))
empty(item()?['0'])
empty()?['0']


The snapshot from my flow:

empty.png

 

The compose 4 content:

[

  {

    "0": "",  →"filter" to avoid the data that the item "0" has empty value

    "1": "Update by AB",

    "2": "Test01",

    "3": "Test10",

    "4": "Test11",

    "5": "Test12",

    "6": "Test13",

    "7": "Test15",

    "8": "Test10",

    "9": "Test15",

    "10": "Test11"

  },

{

    "0": "title 123",

    "1": "Update by AB",

    "2": "Test06",

    "3": "Test76",

    "4": "Test34",

    "5": "Test43",

    "6": "Test68",

    "7": "Test32",

    "8": "Test86",

    "9": "Test54",

    "10": "Test43"

  },

{

    "0": "title 246",

    "1": "Update by AB",

    "2": "Test11",

    "3": "Test1",

    "4": "Test1",

    "5": "Test2",

    "6": "Test3",

    "7": "Test58",

    "8": "Test02",

    "9": "Test04",

    "10": "Test78"

  }

]

 

I require the result:

 

[

{

    "0": "title 123",

    "1": "Update by AB",

    "2": "Test06",

    "3": "Test76",

    "4": "Test34",

    "5": "Test43",

    "6": "Test68",

    "7": "Test32",

    "8": "Test86",

    "9": "Test54",

    "10": "Test43"

  },

{

    "0": "title 246",

    "1": "Update by AB",

    "2": "Test11",

    "3": "Test1",

    "4": "Test1",

    "5": "Test2",

    "6": "Test3",

    "7": "Test58",

    "8": "Test02",

    "9": "Test04",

    "10": "Test78"

  }

]

 

Regards,

ilu989

I have the same question (0)
  • ilu989 Profile Picture
    164 on 02 Oct 2019 at 08:38:45
    Re: Use the Empty in Filter array

    Hi @RezaDorrani @v-alzhan-msft ,

     

    Thanks for your help, it's workable and I found some exception, when the character value has an integer(number), the filter array couldn't recognize, just share what I research, thanks.

     

    [

    {

        "0": 1,   â†’ Integer can't recognize by filiter array

        "1": "Update by AB",

        "2": "Test06",

        "3": "Test76",

        "4": "Test34",

        "5": "Test43",

        "6": "Test68",

        "7": "Test32",

        "8": "Test86",

        "9": "Test54",

        "10": "Test43"

      }

    ]

     

    Regards,

    ilu989

  • v-alzhan-msft Profile Picture
    on 02 Oct 2019 at 06:51:23
    Re: Use the Empty in Filter array

    Hi @ilu989 ,

     

    Have you take a try with @RezaDorrani 's solution , the solution is works, you could also refer to screenshot below in the Filter Array action:

    1.png

     

    @equals(empty(item()?['0']), false)

    Please take a try and let me know if your problem could be solved.

     

    Best regards,

    Alice       

     

    Community Support Team _ Alice Zhang
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

     

  • Verified answer
    RezaDorrani Profile Picture
    12,141 on 02 Oct 2019 at 02:29:32
    Re: Use the Empty in Filter array

    Hi @ilu989 

     

    empty(item()?['0']) - expression on left of is equal to
    false - expression
    Capture.PNG
     
    --------------------------------------------------------------------------------
    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.

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Telen Wang – Community Spotlight

We are honored to recognize Telen Wang as our August 2025 Community…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Tomac Profile Picture

Tomac 986 Moderator

#2
stampcoin Profile Picture

stampcoin 699 Super User 2025 Season 2

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 577 Super User 2025 Season 2

Featured topics