In JQL, you can find issues that have values in a custom field or not by using:
"<customfield_name>" IS EMPTY
"<customfield_name>" IS NOT EMPTY
But what if the issues has no such custom field? For example, we recently added a new custom field that is called ‘division’ to help us to understand where the work comes from. If I do following JQL, it only returns the issues that were created after the ‘division’ field was added.
Project = <project_name> AND "<customfield_name>" IS EMPTY
All the issues that were created before that won’t be returned in the JQL. To find out how many issues that have not such field, here is what you can do:
1) Create a filter to find out the issues that has this custom field,the save it. e.g let’s name it as ‘hasDivsion’.
Project = <project_name> AND ("<customfield_name>" IS EMPTY OR "<customfield_name>" IS NOT EMPTY)
2) Create another filter by using the filter that is created above.
Project = <project_name> AND (NOT filter = "hasDivision")