Greetings
Is there a way to specify null values to be ordered first or last in an ORDER BY clause in JQL?
I'm ordering by a custom field and null values are first by default it seems...
JIRA 6.4 (web version)
Cheers
It's frastrating to have this unfriendly sorting problem.
Please vote and watch the following issues if you have the same problem.
This would be a useful feature. I want to order values for Sprint 1 first, followed by Sprint 2 and so on. So I want to order by Sprints in ascending order. But I also want to show issues not in any Sprint - but at the bottom. Jira seems unable to do this because there seems to be no JQL equivalent of the "nulls last" option in SQL.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
JIRA returns null as first result because in meaning of comparison, null is lower than any another value.
I don't know if you want to order all null columns or only one.
If you are going to order only one, you can use null checkers like:
E.g.
reporter = abc and customfield_1 is not empty order by customfield_1 desc
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This doesn't seem to order the nulls (empties), but rather excludes them.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.