msupply-foundation / open-msupply

Open mSupply represents our most recent advancement in the Logistics Management Information System (LMIS), expanding on more than two decades of development inherited from the well-established legacy of the original mSupply.
https://msupply.foundation/open-msupply/
Other
20 stars 12 forks source link

Default search algorithm #4897

Open mark-prins opened 4 hours ago

mark-prins commented 4 hours ago

Is your feature request related to a problem? Please describe πŸ‘€

this comment talks about searches using a 'contains' query by default and preferring a 'starts with'

Currently all of the search / filter actions which relate to strings are using a 'contains' filter. This will become unwieldy for larger datasets and there's already been some confusion with the search results having entries which are unexpected, due to the 'contains' search.

Describe the solution you'd like 🎁

[ This is still up for discussion and to be updated when agreed upon ]

I'm concerned that

So there's no simple solution. Whatever we decide to do, this needs to apply to all areas of the site:

Describe alternatives you've considered πŸ’­

Additional context πŸ’Œ

Moneyworks Jobcode 🧰

adamdewey commented 3 hours ago

Could we have an option to switch between 'Starts with' and 'Contains' ?

Perhaps it could be hidden in the settings rather than having to show on the UI - but might be nice to able to switch depending on how users prefer?

Oh sorry, saw you already included the option for a switch!