SQL Server – What Does ‘Exclude Rows That Do Not Contain Values’ Checkbox Do in SQL Profiler?

profilersql server

I want to filter a trace and wonder what does 'exclude rows that do not contain values' checkbox exactly do? Is it to filter all the data columns that are not selected in any event class?

Thanks.

enter image description here

Best Answer

It's basically this

WHERE .. AND TheValue NOT NULL

Like/Not like filters only works on values that exist for that event.
No value is always true and passes the filter: this checkbox removes that

For example:

  • You want to see SQL:BatchStarting events
  • You filter on Duration

Duration is not valid for SQL:BatchStarting, so the filter is ignored