Multiple columns searching not working?

Multiple columns searching not working?

csesumonprocsesumonpro Posts: 2Questions: 2Answers: 0

I have a single input outside of the table. I want to search multiple columns but it's not working. It only works for the first index. Is there any solution?

Note: All these columns ar searchable but only work for the first index, If I set first index 1 it will search the index 1 one column but I need to search specific columns through the index.

this.api().columns([0,1]).search(keyword).draw();

Answers

  • allanallan Posts: 63,516Questions: 1Answers: 10,472 Site admin

    this.api().columns([0,1])

    That is an AND filter. It will apply keyword as a search term to both columns. Perhaps that is the issue you are having (without a test case it is hard to say).

    If you want an OR filter, you would currently need to implement a custom search plug-in.

    Allan

Sign In or Register to comment.