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 Apps / Incompatible types for...
Power Apps
Answered

Incompatible types for comparison (yes another one)

(2) ShareShare
ReportReport
Posted on by 19

It's my first post here, but I do see numerous questions similar to this but have been unable to derive the solution to my case from them.   I'm trying to filter a gallery of Purchase Order Lines for the PO Header in the form above it.    I have set a variable coming to the screen for the PO Number.    My good buddy co-pilot can't figure it out and just alternates between two alternatives.

 

Filter('Purchase Order Line', 'PO Number' = varPONum.'PO Number')
Yields Incompatible type comparison: Record, Text.

OK, so we'll just try the variable with type record:
Filter('Purchase Order Line', 'PO Number' = varPONum)  

But that comes back with Incompatible type comparison: Record, Record.      This one really flummoxes me because... well, if the data type is the same you should be able to compare them, right?


Categories:
I have the same question (0)
  • KeithAtherton Profile Picture
    3,709 Most Valuable Professional on at

    Hi @Bandito,

     

    Does this code work?:

    Filter('Purchase Order Line', 'PO Number'.'PO Number' = varPONum.'PO Number')

    If I have answered your question, please mark your post as Solved.
    If you like my response, please give it a Thumbs Up.
    Connect with me online.

  • Bandito Profile Picture
    19 on at

    No, I think I did try that in one of my iterations with the chatbot as well.  🙂     That gives me 'Name isn't valid' (shown below)

    Bandito_0-1720636124582.png

     

  • Verified answer
    KeithAtherton Profile Picture
    3,709 Most Valuable Professional on at

    What does intellisense display when you type 'PO Number'.?

     

    I'm expecting the record provides a column that can be used.


    If I have answered your question, please mark your post as Solved.
    If you like my response, please give it a Thumbs Up.
    Connect with me online.

  • Bandito Profile Picture
    19 on at

    Ding ding ding ding ding!    I think I just copy/pasted it in from your post so I didn't get the context hints.    
    This seems to work:

    Filter('Purchase Order Line', 'PO Number'.value = varPONum.'PO Number')

     

  • KeithAtherton Profile Picture
    3,709 Most Valuable Professional on at

    "Ding ding ding ding ding!", love it! 😁

     

    Great news, well done for getting it working and thanks for the update.


    If I have answered your question, please mark your post as Solved.
    If you like my response, please give it a Thumbs Up.
    Connect with me online.

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

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 326 Most Valuable Professional

#2
11manish Profile Picture

11manish 168

#3
sannavajjala87 Profile Picture

sannavajjala87 75 Super User 2026 Season 1

Last 30 days Overall leaderboard