Skip to main content
June 15, 2021
Solved

Multiple Dropdown for query filter

  • June 15, 2021
  • 3 replies
  • 0 views

Hello All,

I have a multiple dropdown that have values ex. "ACTIVE", "PENDING, "INACTIVE".  I need to display all the details with a status like ACTIVE and PENDING. However, I can't do it using a!queryFilter. Here's my line up code for filter.


a!queryFilter(
field: "status",
operator: "includes",
value: ri!statusSearch,
applyWhen: not(isnull(ri!statusSearch))
)

Best answer by acaciob0002

Hi Rainier,

I'm assuming that your rule input statusSearch is defined as Array to receive the multiple values, and probably this is the reason why the operator "includes" is failing.

You can try to use the operator 'in', but the behavior of this operator is different from includes, however for your case where you are searching for the full string ACTIVE and PENDING I don't think it will be a problem.

Could you please try and let us know if it solved your problem?

Regards,

Acacio B.

3 replies

acaciob0002
June 15, 2021

Hi Rainier,

I'm assuming that your rule input statusSearch is defined as Array to receive the multiple values, and probably this is the reason why the operator "includes" is failing.

You can try to use the operator 'in', but the behavior of this operator is different from includes, however for your case where you are searching for the full string ACTIVE and PENDING I don't think it will be a problem.

Could you please try and let us know if it solved your problem?

Regards,

Acacio B.

June 15, 2021

Hello sir Acacio, yes it works. I just changed the operator to "in". Thank you so much!

acaciob0002
June 15, 2021

That is good!!

cheers