cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
dviviani
New Member

Filter multi select choice

Hello everyone.

I'm trying to filter and search a SharePoint list that I use to store my customer information.

 

On Start = ClearCollect(colProdutos,Choices(Clientes.Produtos))

List = Clientes

Multi Choice column = Produtos

ComboBox1_3 = colProdutos

Gallery =

Search(
Filter(
Clientes,
IsBlank(ComboBox1_3.SelectedItems.Value) || IsEmpty(ComboBox1_3.SelectedItems) || Produtos in ComboBox1_3.SelectedItems
),
TextInput1_1.Text,
"C_x00f3_digo",
"Raz_x00e3_oSocial",
"gv8l"

 

I followed the video https://www.youtube.com/watch?v=5dSk5iOgT68 but for some reason, it is not working. Can anyone give a tip here?

Thanks in advance

1 ACCEPTED SOLUTION

Accepted Solutions
v-albai-msft
Community Support
Community Support

Hi @dviviani ,

This is because your combo box allows multiple selections, and also your SP Produtos column is a multiple choice column. You cannot directly compare their results. Because both their results return a table. 

But in the video you mentioned, his choice column in DataSource doesn’t allow multiple selection.

So for your requirement, you can try this formula on your gallery(pay attention to the third condition inside Filter function):

Search(
Filter(
Clientes,
IsBlank(ComboBox1_3.SelectedItems.Value) || IsEmpty(ComboBox1_3.SelectedItems) || 
ID in Ungroup(ForAll(ComboBox1_3.SelectedItems,Filter(Clientes,Value in Produtos.Value)),"Value").ID),
TextInput1_1.Text,
"C_x00f3_digo",
"Raz_x00e3_oSocial",
"gv8l")

Best regards,

Allen

View solution in original post

4 REPLIES 4
CNT
Super User
Super User

@dviviani to isolate the problem, its good to break it down. Is Filter part alone working as expected?

v-albai-msft
Community Support
Community Support

Hi @dviviani ,

This is because your combo box allows multiple selections, and also your SP Produtos column is a multiple choice column. You cannot directly compare their results. Because both their results return a table. 

But in the video you mentioned, his choice column in DataSource doesn’t allow multiple selection.

So for your requirement, you can try this formula on your gallery(pay attention to the third condition inside Filter function):

Search(
Filter(
Clientes,
IsBlank(ComboBox1_3.SelectedItems.Value) || IsEmpty(ComboBox1_3.SelectedItems) || 
ID in Ungroup(ForAll(ComboBox1_3.SelectedItems,Filter(Clientes,Value in Produtos.Value)),"Value").ID),
TextInput1_1.Text,
"C_x00f3_digo",
"Raz_x00e3_oSocial",
"gv8l")

Best regards,

Allen

Hi CNT.

No, it wasnt. The reply below solves the problem. Tks for your reply anyway 🙂

Thank you very much!!

Helpful resources

Announcements
Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Power Apps Ideas

Check out the New Ideas Site

We are excited to announce a new way to share your ideas for Power Apps!

Top Solution Authors
Top Kudoed Authors
Users online (4,372)