Using the Regex not operator for searching
Using the Regex not operator for searching
I am trying the example for Regex search that is here: https://www.datatables.net/release-datatables/examples/api/regex.html
I want to search for columns that do not have a certain value.
So I did the following. For the office column select Regex search and disable smart search.
Now search for all rows where office is not equal to London.
To do so I typed
^(London)
Yet, the search results in all rows where office is equal to London.
What am I doing wrong?
The following regex does the trick
^((?!(london)).)*$
Not sure why negative look ahead works but ^(London) doesn't.
Answers
Hi @karthikk ,
This thread here discusses that - hope it helps,
Cheers,
Colin