Why oh why am I unable to search the DB case insensitive?

Is this still an issue?

I can only lowercase the right hand side (user input), but not the left hand side (database field). See image below

So the only workaround now is to have a duplicate database field but all-lowercase?

image

3 Likes

Yup, still an issue

1 Like

Gracias … Bueno

@Dev.Appassion

Step 1: Create a searchbox and create a workflow off of the value changing. First thing is to create a custom state on the searchbox in the workflow and set it to lowercase value of searchbox.
Step 2:Next Action->Element Actions->Display List->Select the element
Step 3:Data source->Search for . Give it some criteria that will pull back a larger list than what you are expecting
Step 4:Click more or select :filtered from dropdown. Add a new constraint-> Advanced at bottom of dropdown. Now says Advanced:
Step 5:Advanced features include converting THIS group results to :lowercase. Filter where contains the custom state that was created in Step 1. You can also use and/or for more advanced criteria.

To recap: When the searchbox is change, its custom state should be updated to being the lowercase format of the input. Next, do a search for records and then filter where the constraint starts with Advanced. In the Advanced section, THIS :lowercase contains searchbox’s custom state.

2 Likes

Until its possible to make it any other way without using plugins or flooding db with duplicate fields, here is what worked quite fine for me.

Advanced: XXX’s NAME:lowercased contains INPUT’s value or XXX’s NAME:uppercase contains INPUT’s value or XXX’s NAME:capitalized words contains INPUT’s value or XXX’s NAME contains INPUT’s value

Still testing it and it seems to work, but it does the trick if you type in lowercase or uppercase or capitalised word or exactly the way your name uses capital letters. Of course it won’t work if you type mixed uppercase and lowercase characters in the middle, but c’mon, who does that ))

1 Like

I had the same problem and found out that you can use the free plugin called: ZQ Fuzzy Search & Autocomplete to do this. Here’s a youtube video showing how to use it. Hope this helps someone :slight_smile:

2 Likes

:capitalized words

…does the trick for me

1 Like

It’s still a workaround, but I’ve posted a method that is working pretty well for me without API’s or other fancy workarounds. A quasi solution for some Case-Insensitive searches in Bubble

“contains keyword(s)” works great!

2 Likes

@NigelG I personally always find the advanced search to not be performant in production level tools with hundreds of thousands of rows. Have you found the same?

2 Likes

Yes. You really need to constrain the search as much as possible before you use it.

1 Like

I’ve got a typesense/algolia plugin in closed beta that solves this issue quite nicely (returns instant results regardless of if there are 100 or 100,000 records in the database. DM me if interested and we can chat more/I can link you the demo :slight_smile:

1 Like

Works great! Thanks

I wrote to you. I would like to try the plugin connecting to Typesense…

1 Like

I just replied to you

For those still searching for case insensitive and partial filter / search in bubble. This is possible without a plugin or hack, though not straightforward. Here is a great video by bubbleHacks explaining the process. You don’t need the first part but only the second part starting at 5:15 How to implement lightning-fast case insensitive search in Bubble - YouTube

3 Likes

You don’t need to duplicate your database or have a separate field or save a new state. Just use an advanced filter to process the field as lowercase and then process the search input as lowercase as well.

Here is an example of using it to search for contacts within a list who have a first name containing text from an input field:

@deliriousmiles this might have been a viable solution before, but with Bubble’s new WU pricing, using advanced filters will cost you a lot of money and kill your app.

How are you able to do that?

Bubble won’t allow me to add lowercase on the search term:

I am getting around this by comparing it against an arbitrary text and there applying the lowercase.

Still I find it weird that you can do this while I can’t.

Anyway, using filter over a search is super slow. I just don’t see why there still isn’t an option to just search search case insensitively. :frowning: