Power Automate Exchange

Please login or click SIGN UP FOR FREE to create your FlowUG account to join this user group.
  • 1.  Filter Array

    Top Contributor
    Posted Aug 30, 2021 09:20 AM

    I am trying to extract details from an email, I've managed to capture the received email, get the body contents (HTML) pass it through a select to assign a field name, now I'm trying to filter that select array to return only the lines that match this string, but the filter array doesn't return any results. Any ideas what I'm missing?

     

    Compose = Body of email (HTML)

     

    Append To Array Variable "EmailOutput":

    {

      "BodyLines": @{split(outputs('Compose'),'>')}

    }

     

    Select:

    {

        "inputs": {

            "from""@variables('EmailOutput')",

            "select": {

                "BodyLines""@item()?['BodyLines']"

            }

        }

    }

     

    Filter Array:

    {

        "inputs": {

            "from""@body('Select')",

            "where""@or(contains(item()?['BodyLines'], 'tasks.office.com%2Fxxx.onmicrosoft.com'),contains(item()?['BodyLines'], 'tasks.office.com'))"

        }

    }