Datablaze query: include null values

Hello!
I am trying to build a datablaze system to store text that then is pulled by the snippets depending on different variables.

I have a column called employee_type and a variable in the snippet with the same name, that lets the user choose betwen "Value1" and "Value2".

I am trying to get the query to select all rows that include either the specific employee_type value or empty value, something like SELECT reason,message FROM extra WHERE includes(employee_type, @employee_type) OR employee_type is NULL AND country = @country AND employee_type

A screenshot of the table here:

Captura de pantalla 2023-11-23 a las 15.27.07

Any help? I can't seem to be able to do it by myself.

Appreciate the help,

Lidia

Hi!

That looks like a multi select field, is that correct?

If so you can query the empty fields by comparing the field value to an empty list. For example:

employee_type = []

Let me know if that helps

Thanks! I made it work by using WHERE (employee_type= [] OR includes(employee_type,@employee_type))

Glad to hear it!