Hey!
I'm having an issue with a drop down list on my app.
I have one simple radio control with 3 options (OPT1, OPT2 and OPT3) that filter the column AREA fro my database. When I select one of them, it filters the name's column with the names that correspond to the AREA selected in the radio button.
This is the formula that I'm using in items in my drop down:
SortByColumns(Distinct(Filter(MY_DATABASE;Radio_area.Selected.Value=AREA);NAMES);"Result";If(SortDescending1; Descending; Ascending))
My database is a SharePoint list with 4.500 itens. The issue is that when selected, OPT1 should populate the drop down with 68 names but it's only getting 65 of them.
The OPT2 return the 49 values and OPT3, 30 values (all correct).
If I try to change the missing names from OPT1 to OPT2, they appear correctly.
So, is there any limitation in drop down lists with large numbers?
Solved! Go to Solution.
Hi @plwms,
I have experienced this issue and I was able to resolve this. Based on my experience here are 2 possible solutions:
I have seen this issue mostly encounter while we implement cascading dropdown lists.
I hope this resolved your issue if you see any challenge let me know I am always happy to help.
Regards,
Krishna
If this post helps give a 👍 and if it solved your issue consider Accept it as the solution to help the other members find it more.
Using @KrishnaV's idea, I found a solution!
I created a new SP list with two colums: a list of names that I wanted to show in my drop down (with the same names that I have in my first SP list) and the OPT from radio button associated to that name. The first colums is called NAME and the second AREA_NAME, respectively.
Then, I used that entry in Items:
ForAll(Filter(DATABASE_2_WITH_2COLUMNS; AREA_NAME = Radio_area.Selected.Value); NAME)
This is working for me 🙂
Hi @plwms
Distinct is not a delegatable function so it will only apply to the first 2k items in your list. One way to deal with it is to create two collections, one sorted ascending and the other sorted descending. You can then combine them.
Collect(colAsc,Sort(yourlist,ID,Ascending));
Collect(colDesc, Sort(yourlist, ID, Descending));
Collect(colFinal,colAsc,colDesc)
then use colFinal in your formula for the Items property of the dropdown instead of MY_DATABASE and look at how that compares with what you were doing before. Since your list is 4500, there are still 500 items that won't be included in your combined collection. Is it possible to get your original list down from 4500 to 4000 by prefiltering it according to your Radio selections, collecting each result and then combining the collections and then using Distinct() on the final combined collection.
The issue is that in SharePoint, Filter() is delegatable and so there is no limit on the number of items obtained by a filter. However, Collect(), ClearCollect() and Distinct() are not delegatable and so these functions are limited to no more than 2000 items but once collected, virtually all PowerApps functions are available to use as there are no delegation limits applied when the data source is a collection.
Hi @plwms,
I have experienced this issue and I was able to resolve this. Based on my experience here are 2 possible solutions:
I have seen this issue mostly encounter while we implement cascading dropdown lists.
I hope this resolved your issue if you see any challenge let me know I am always happy to help.
Regards,
Krishna
If this post helps give a 👍 and if it solved your issue consider Accept it as the solution to help the other members find it more.
Hi, @KrishnaV!
I think I understood but i've never worked that way with these options... Do you have any example?
Hey, @Drrickryp!
Thanks for your answer. Actually, I can't reduce my SP list... Maybe the solution would be make a "loop" with collections until it reaches the end of SP list to collect all of the entries?
Using @KrishnaV's idea, I found a solution!
I created a new SP list with two colums: a list of names that I wanted to show in my drop down (with the same names that I have in my first SP list) and the OPT from radio button associated to that name. The first colums is called NAME and the second AREA_NAME, respectively.
Then, I used that entry in Items:
ForAll(Filter(DATABASE_2_WITH_2COLUMNS; AREA_NAME = Radio_area.Selected.Value); NAME)
This is working for me 🙂
User | Count |
---|---|
256 | |
110 | |
90 | |
51 | |
44 |