cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
anubhav247
Frequent Visitor

Filter gallery based on a choices type column in dataverse for teams App

Hello Geniuses,

 

I am trying to build a Dataverse for Teams App.

 

I have a dataverse table called "Patient". Inside this table, there is a column called gender. This column is of type Choices(Not Choice).

The name of the choice is "Gender Choices" and it has three options "Male", Female and "Transgender"

 

I have a gallery whose items property is set to "Patients".

 

I want to filter the gallery items based on gender column. Based on what has been shown in the video here (@ 06:35 ) i am using below formula which is resulting in an error

anubhav247_0-1621285386879.png

Now i have 2 questions

1) In the video, reza is not using dataverse for team, Should it matter?

2) What can i change to make the formula work without running into delegation problem?

 

Thanks in advance!!

Regards,

Anubhav 

 

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @Anubhav_Gupta

Actually, if there is no need to use a Choices field, we suggest you use the Choice type.

In addition, PowerApps settings could support 2000 records at most, if you do not have a huge data set, the "in" operator is enough for you. However, if you have a huge data set that exceeds 2000, here is a similar thread that @ PaulD1 has a answer for this, please check as below.

Re: Canvas App - Filter Product records of Dynamic... - Power Platform Community (microsoft.com)

Best Regards,

Qi

Best Regards,
Qi

View solution in original post

12 REPLIES 12
v-qiaqi-msft
Community Support
Community Support

Hi @anubhav247,

Do you want to filter the gallery based on a Choice column?

Could you please share a bit more about your scenario?

Please modify your formula as below:

Filter(Patients,'Gender Choices'='Gender Choices (Patients)'.Female)

v-qiaqi-msft_0-1621316460569.png

Regards,

Qi

 

Best Regards,
Qi

Gender Column

anubhav247_0-1621324487971.png

Gender Column Properties

 

anubhav247_2-1621324563658.png

Gender Column Choices Properties

 

anubhav247_3-1621324678456.png

Filter formula am using

anubhav247_4-1621325548166.png

 

 

 

Hi @anubhav247

Have you tried my solution?

I want to confirm with you that if you really use the Dataverse for Teams, then the Patient table should look like this:

v-qiaqi-msft_0-1621325980202.png

There is no Choices column type there.

If you want to create a canvas app for Teams, you could only create a Choice column.

In addition, Choices field type means multi select that a gender may not be multi select.

If you just want to select a gender, you could just create a Choice field.

Regards,

Qi

 

 

Best Regards,
Qi

@v-qiaqi-msft I'm having the same issue in the normal PowerApps. This used to work fine. Newly created Choices are creating problems. As you are from MS, please take it up with the product team. Thanks.

CNT_0-1621328521040.png

 

 

Hey Qi,

 

Am using dataverse for teams only.

I believe, there is more than one way to add columns, you get choices option when you try it the other way. 

Anubhav_Gupta_0-1621329008579.png

Regards,

Anubhav

Hi @Anubhav_Gupta,

My bad.

I could achieve this in your way.

However, please answer me this question I asked before:

Choices field type means multi select, are you sure that multi select genders for a same record?

EDIT here:

Filter(Patients,Gender.Male in 'Gender Choices')

Currently

Regards,

Qi


Best Regards,
Qi

@v-qiaqi-msft 

Look at my example, there's no Gender there. It's Person Category and still the same error. Why don't you try to replicate the issue on your side and quickly reach out to the product team. I'm almost sure there is something seriously wrong as someone else also had a similar issue yesterday. Thanks!  

Hey Qi,

 

Not sure i understand your question. In my case, gender is a Choices type field. I am not allowing multi-select.

 

using the "in" operator causing delegation issues so i avoid that.

Anubhav_Gupta_0-1621333381991.png

 

 

Regards,

Anubhav 

Thanks Qi,

 

I now understood the problem.

 

The gender field should have been a Choice type rather than a ChoiceS type.

 

I recreated the field and now it is working.

However i am still wondering is there is away to filter choices column without running into delegation issue. 

 

Thanks again.

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Users online (2,449)