evidence icon indicating copy to clipboard operation
evidence copied to clipboard

[Bug]: Long Dropdown Loading time when several values are selected by default

Open chapeaupaul opened this issue 11 months ago • 2 comments

Describe the bug

When working with many distinct values and dropdown filters, the loading time is impacted, making the dashboard impossible to use. See loom video

Steps to Reproduce

https://www.loom.com/share/6d5e4bbee84c49d9a677b55c16111107

chapeaupaul avatar Jan 07 '25 17:01 chapeaupaul

Related to inlining all the default values in the array into the where clause

archiewood avatar Jan 07 '25 18:01 archiewood

Would changing the behavior of selectAllByDefault or allowing a selectNoneByDefault that returns null or a value that lets us write SQL to skip the where clause when nothing is selected in a multi-select dropdown solve the performance issue? I'm experiencing a similar issue from a usability perspective. I'd rather have the multi select uncheck everything by default, which means return all data, and then filter it down with a few selections when needed.

However, the current behavior on first load with nothing selected causes the queries to hang:

Image

Making a selection, and then deselecting, still returns (select null where 0) without the comment, but now the queries process:

Image

nickfanion avatar Jan 07 '25 19:01 nickfanion