Dropdown filter that returns empty options from the database

Hello, could anyone help me? I want to fetch only the Yes/No options from the database and show them in my Dropdown to create a filter on a repeating group element. However, when the data arrives, it brings fields into the database.

I can’t take a print with the dropdown open, as it closes before the print. But basically it opens like this:

field 1: Blank space
field 2: Yes
field 3: Blank space
field 4: No

My DB configs


If I click on the first blank field in the dropdown it brings up all the user’s tasks.
{75B2278B-4394-4C59-AB72-891F969B0F44}

If I click on the Yes dropdown it only brings up the completed tasks
{1E94F612-2564-4C80-B6B5-1D406A0CD482}

If I click on the third option in the blank dropdown it brings all the tasks back again
{B801F27B-CB8C-4158-A288-59D362250150}

If I click on the No option in the dropdown, it only brings up pending tasks.
{F1DE8D60-C4A5-4C0E-9734-24D8916F1AF8}

Dropdown Menu

Repeating Group

Can you not add a constraint to the search to mitigate the blank values?

[task_done] is not blank?

Sorry, I’m new to Bubble. I’m still learning, do I add this constraint to the repeater group or to the dropdown element?

Would it be here?

Instead of ‘=’ what options are you given?

These are the options

I think for dropdown you should use static values i.e Yes & No.

And then wherever you need to use the dropdown’s value in a constraint, you should add the expression, " Dropdown’s value is Yes".

1 Like

As @singhsahib has said, you can use static values, then match the rows to the values.

Alternatively, if you don’t want to backtrack, just select ‘isn’t empty’.

1 Like

Thank you, it worked… investigating here, I just needed to set the task_status default to No in the database, as it understands that it has 3 options, blank, yes and no. This already eliminated the duplication problem, and to remove the blank field, just mark in the dropdown that it could not be empty and it worked. Thanks

1 Like