searching for null values
searching for null values

Hi,
I am trying to create an initial search filter that matches if the second field of the table has null values:
searchCols: [
null,
{ search: null }
]
That however produces the following exception: "Uncaught TypeError: Cannot read property 'replace' of null"
If I change to { search: "" } then no exception occurs, but this does not match explicit null values.
Any ideas?
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
Currently DataTables built in search is entirely string based - which is why you are getting an error there. If you want to search for
null
exactly then you would need to use a custom plug-in search function.Allan
yes, you are right, I complete forgot about custom search plugins!
Thanks!