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 Automate
Answered

Invalid Template

(1) ShareShare
ReportReport
Posted on by 5

Hello,

 

Please, someone can help me with the next problem.

 

I´m trying to filter a matrix with the next code: "@and(equals(item()?['FECHA LEGALIZACIÓN EN FINANCIERA'], ''), greater(item()?['DIFERENCIA DÍAS'], 3))", the firts column is a string type column an the second is a integer type column, but it´s showing me the next error: "The execution of template action 'Filtrar_matriz' failed: The evaluation of 'query' action 'where' expression '@and(equals(item()?['FECHA LEGALIZACIÓN EN FINANCIERA'], ''), greater(item()?['DIFERENCIA DÍAS'], 3))' failed: 'The template language function 'greater' expects two parameter of matching types. The function was invoked with values of type 'String' and 'Integer' that do not match.'."

 

I´m completely sure that the column "DIFERENCIA DÍAS"  is an integer type column but it´s continue saying me that there are string and integer values.

 

Somebody could give me some recomendations on how to solve this problem.

 

Thank you.

Categories:
  • Verified answer
    sandeepstw Profile Picture
    312 Moderator on at

    Hi There,

     

    It looks like that there's an issue with the data type for the "DIFERENCIA DÍAS" column. Due to "DIFERENCIA DÍAS" might be blank or null. 

     

    You can use this this expression to check blank and null for the column - 

     

    "@and(equals(item()?['FECHA LEGALIZACIÓN EN FINANCIERA'], ''), if(equals(empty(item()?['DIFERENCIA DÍAS']), true), false, greater(int(item()?['DIFERENCIA DÍAS']), 3)))"

     

    Please give kudos and mark as solution if it helps.  

      

    Thanks, 

    Sandeep Mishra 

     

  • Luis2505 Profile Picture
    5 on at

    Hey, thank you for your suggestion,

     

    It doesn´t work, but you gave an idea about how I can solve the problem and I did it.

     

    Thank you so much

     

     

  • sandeepstw Profile Picture
    312 Moderator on at

    Hi Luis,

     

    Thanks, as you are a developer you know what changes you need to make in my answer, as a solution provider I can give direction.

     

    But if you think my idea or solution was helpful please mark as solution. Thanks again !

     

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Automate

#1
11manish Profile Picture

11manish 302 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 263

#3
Henil Profile Picture

Henil 115

Last 30 days Overall leaderboard