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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Filter by comparing a ...
Power Apps
Unanswered

Filter by comparing a Lookup field to a text field in two different Dataverse tables

(0) ShareShare
ReportReport
Posted on by 9

Hello, I am trying to create a nested gallery, where the first gallery displays the Categories and depending on the category selected it should go to a gallery that contains the Awards that fall within that category. for the filter on the second gallery (Awards gallery), I am trying to compare two different fields in two different tables in Dataverse. Table 1 is called Kudos Category, Table 2 is called Kudos Award. Kudos Award table has a lookup field called 'Kudos Category' that gets the category from the Kudos Category table, field name: 'Kudos Category Name' (which is a text input).

 

I have tried:

Filter('Kudos Category'= galKudosCategories.Selected.'Kudos Category Name')

Filter('Kudos Category'.Value = galKudosCategories.Selected.'Kudos Category Name'.Value)

 

and neither of them work

Categories:
I have the same question (0)
  • Vikas_Sharma Profile Picture
    42 on at

    Hi @Lsmits 

    Please check the syntax of the filter function because It should contain the database name first and then the condition.

    In your filter syntax you have not used the database name please add that and then check.

    Hope this will work.

     

     

    Thanks, Regards

     

     

     

  • Lsmits Profile Picture
    9 on at

    Hi Vikas,

     

    yes apologies, it does and it still doesn't work:

     

    Filter('Kudos Awards', 'Kudos Category'= galKudosCategories.Selected.'Kudos Category Name')

    Filter('Kudos Awards', 'Kudos Category'.Value = galKudosCategories.Selected.'Kudos Category Name'.Value)

     

    any suggestions?

     

  • Verified answer
    Lsmits Profile Picture
    9 on at

    I figured it out!

     

    Because the 'Kudos Category' is a lookup column from Dataverse you need to reference the lookupcolumn.columnameitislookingupfrom eg.

     

    Filter('Kudos Awards', 'Kudos Category'.'Kudos Category Name' = galKudosCategories.Selected.'Kudos Category Name')

  • v-LilyW-msft Profile Picture
    on at

    Hi @Lsmits 

    Thanks for your posting here and sharing the solution in the forum as it would be helpful to anyone who encounters similar issues. Please accept your reply as an solution to mark the post as solved so that this thread will be marked for other users to easily identify!

    Best Regards.

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 717 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 329 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard