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 / I'm confused with 'Cho...
Power Apps
Answered

I'm confused with 'Choice' columns and the filtering in Canvas apps

(0) ShareShare
ReportReport
Posted on by 710

So, I think I'm a little confused.

 

I have a Dataverse Table with the following settings: for the Column - 'Approval Status'

approvalsettings.png

 

When comparing them / trying to filter in Canvas I find I usually have to refer to them as = 10 for Pending approval etc. 

Doesn't seem to work when trying to use the Text values.

 

Eg, In a gallery I am using the below which works.:

 

Sort( 
 Filter(GB_Recipients, 'Approval status' = 20),
'Created On',
SortOrder.Descending
)

 

But this doesn't:

 

Sort( 
 Filter(GB_Recipients, 'Approval status' = "Approved"),
'Created On',
SortOrder.Descending
)

I want to compare to the actual text instead of the number value.

 

What am I doing wrong 🙂

 

Thank you
 

I have the same question (0)
  • Ami K Profile Picture
    15,689 Super User 2024 Season 1 on at

    @RandomDept ,

     

    For a Local Choice, try:

     

    Sort(
     Filter(
     GB_Recipients,
     'Approval status' = 'Approval status (your table plural name)'.Approved
     ),
     'Created On',
     SortOrder.Descending
    )

     

     

    For a Global Choice, try:

     

    Sort(
     Filter(
     GB_Recipients,
     'Approval status' = [@'Approval status'].Approved
     ),
     'Created On',
     SortOrder.Descending
    )

     

     

    ------------------------------------------------------------------------------------------------------------------------------

     

    If I have answered your question, please mark your post as Solved. Remember, you can accept more than one post as a solution.

    If you like my response, please give it a Thumbs Up.

    Imran-Ami Khan

  • RandomDept Profile Picture
    710 on at

    Thank you, sadly I'm getting:

     

    Name isn't valid 'Approval status' isn't recognized.

    Invalid use of '.'

    Incompatible types for comparison

     

  • Ami K Profile Picture
    15,689 Super User 2024 Season 1 on at

    @RandomDept could you share an image of the error message in the expression

  • Verified answer
    Ami K Profile Picture
    15,689 Super User 2024 Season 1 on at

    @RandomDept - I just noticed the name of your Global Choice is "Approval".

     

    Change the expression to:

     

    Sort(
     Filter(
     GB_Recipients,
     'Approval status' = [@Approval].Approved
     ),
     'Created On',
     SortOrder.Descending
    )

     

    ------------------------------------------------------------------------------------------------------------------------------

     

    If I have answered your question, please mark your post as Solved. Remember, you can accept more than one post as a solution.

    If you like my response, please give it a Thumbs Up.

    Imran-Ami Khan

  • RandomDept Profile Picture
    710 on at

    Thank you!

     

    query.png

     

    errors.png

  • Ami K Profile Picture
    15,689 Super User 2024 Season 1 on at

    @RandomDept - see the earlier message

  • RandomDept Profile Picture
    710 on at

    No luck on the local version either sadly 😞

    Untitled.png

  • RandomDept Profile Picture
    710 on at

    Thank you so much

  • Ami K Profile Picture
    15,689 Super User 2024 Season 1 on at

    @RandomDept -

     

    Not sure if you saw my earlier message. You need to input the name of your Global Choice, not the Dataverse table name.

     

    You can find the name of your Global Choice via the Choices menu:

     

    Amik_1-1693534907544.png

     

    ------------------------------------------------------------------------------------------------------------------------------

     

    If I have answered your question, please mark your post as Solved. Remember, you can accept more than one post as a solution.

    If you like my response, please give it a Thumbs Up.

    Imran-Ami Khan

     

  • RandomDept Profile Picture
    710 on at

    Thanks again, you rock!

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 July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 358 Most Valuable Professional

#2
11manish Profile Picture

11manish 207 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 150 Super User 2026 Season 2

Last 30 days Overall leaderboard