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 to make a Date as ...
Power Automate
Unanswered

How to make a Date as a condition in the Filter Array action

(0) ShareShare
ReportReport
Posted on by 160

I have 2 data in my excel sheet, [Alert Type] and [Date]. I am looking into how to make these 2 data into a condition in my "Filter Array" action in Power Automate. Below is the screenshot of my data from an excel sheet:

DelDev_0-1718691395595.png

 

The condition for [Alert Type] and [Date] for the "Filter Array" action I'm looking into is if ([Alert Type] is greater than Red4) AND ([Date] is equal to OR after the current date). I know how to make the [Alert Type] as a condition: 

    less(int(split(item()?['Alert Type'], 'Red')?[1]), int('4')) but I'm interested to know how to make the condition for if([Date] is equal to OR after the current date) and afterwards combine it with the condition of the [Alert Type] to if ([Alert Type] is greater than Red4) AND ([Date] is equal to OR after the current date). Any methods or techniques is appreciated, thanks in advance!
Categories:
I have the same question (0)
  • v-mengmli-msft Profile Picture
    Microsoft Employee on at

    Hi @Del-Dev ,

     

    Please try this.

    @and(less(int(split(item()?['Alert Type'], 'Red')?[1]), int('4')),greaterOrEquals(item()?['Date'], utcNow('dd-MMM-yy')))

     

     

    Best regards,

    Rimmon

  • Del-Dev Profile Picture
    160 on at

    Hi @v-mengmli-msft,

    Thank you for your suggestion! I have tried it but when I changed the date beside the "Red2" to "16-Jun-24", my expected outcome would be that I would not be able to print anything because both conditions: ([Alert Type] is less than Red4) AND ([Date] is equals to OR after the current date) and must be satisfied to print something. When I ran the flow in Power Automate, it still prints out something even I have changed the date to 16-Jun-24 and both conditions is not satisfied. Please advise me on this, thank you!

  • v-mengmli-msft Profile Picture
    Microsoft Employee on at

    Hi @Del-Dev ,

     

    Could you please show some screenshots about your flow?

    Here is my test. I think it works well.

    The second item meets two conditions.

    1.less than red4 .

    2.greater than or equal to current date.

    vmengmlimsft_0-1718696200716.pngvmengmlimsft_1-1718696257670.png

     

     

    Best regards,

    Rimmon

  • Del-Dev Profile Picture
    160 on at

    Hi @v-mengmli-msft,

    Below are the screenshots:

     

    DelDev_5-1718697676020.png

     

    DelDev_6-1718697858335.png

     

     

    DelDev_2-1718697303510.png

    DelDev_4-1718697588979.png

     

  • v-mengmli-msft Profile Picture
    Microsoft Employee on at

    Hi @Del-Dev ,

     

    This is because we are using different date formats.

    Your Date column is in dd-MM-yyyy format. Please modify date format in filter array.

    vmengmlimsft_0-1718698157365.png

     

     

    Best regards,

    Rimmon

  • Del-Dev Profile Picture
    160 on at

    Hi @v-mengmli-msft,

    Below is the screenshot of the format I have changed:

    DelDev_0-1718698581008.png

     

    The date 15-06-24 is still printed:

    DelDev_1-1718698703741.png

     

     

  • v-mengmli-msft Profile Picture
    Microsoft Employee on at

    Hi @Del-Dev ,

     

    What does the output of Date column in List rows in a table?

    Please check if the format in Filter array is same to above.

     

    Best regards,

    Rimmon

  • Del-Dev Profile Picture
    160 on at

    Hi @v-mengmli-msft,

    The screenshot below is the output of List rows in table:

    DelDev_0-1718699585211.png

    DelDev_1-1718699661825.png

     

    I have tried these formats that you have suggested earlier for the Filter Array:

     

    DelDev_4-1718699947154.png

     

    DelDev_3-1718699872078.png

     

  • v-mengmli-msft Profile Picture
    Microsoft Employee on at

    Hi @Del-Dev ,

     

    Please turn on this setting.

    vmengmlimsft_0-1718700755935.png

    Then use yyyy-MM-dd in filter array.

     

     

     

    Best regards,

    Rimmon

     

  • Del-Dev Profile Picture
    160 on at

    Hi @v-mengmli-msft,
    The Filter Array is working now, but I have an error for my "Select" action. Below is the screenshot of the error:

    DelDev_0-1718701849392.png

     

    And the below screenshot is my "Select" action:

    DelDev_2-1718702062547.png

     

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!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 250 Super User 2026 Season 1

#2
Expiscornovus Profile Picture

Expiscornovus 222 Most Valuable Professional

#3
Haque Profile Picture

Haque 174

Last 30 days Overall leaderboard