Typical three-valued (null/false/true) DB field in JIRA?

I m giving the IT-guys the fits here with the wish for a custom field - vanilla three-valued (null/false/true) DB field.

"None" seems somehow to be synonymous with Null I m told and carved in stone, but "None/False/True" or "None/No/Yes" doesn t make sense, while "Null" or "Unknown" for the first default value would be perfect.


PS: Just got a 504 from the Answers site and pressed Reload. Guess that s why the topic appears twice!!!

2 answers

1 accepted

0 votes
Accepted answer

There is no really good solution.

We took a text field. If it s empty I need to check. If it s Yes, action is needed, else No...

0 votes

Well, the true/false bit is a doddle in a select list, but I can see the ugliness with "null"

Jira always offers "none" in a select list, but it's not a null, it's a fourth state. For the users it really means "I choose not to enter the data", and in the database, it means "don't even create a record for this". Which is not even "null", it's "nothing there at all". Of course, the code doesn't like "null" in the database, so you never end up with a record and a null.

I think what you really want to do is

1. Add a field as usual, with Null, True and False

2. Supress Jira offering "none" to the users

That will give you a field which is always set to null, true or false, no matter what. Unfortunately, you'll need to do a bit of tweaking to do this - have a quick search here for "Jira" and "none" and "Select" and you'll see you're not alone.

Another option might be to hack the language and replace "none" with "null", but that'll make the other fields look odd...

Veeery quick followup b4 I leave for the long weekend:

Change None no option - too dangerous to change company-wide semantics.

Any other way to suppress None?

Any other custom field type like Label e.g. that allows the three desired values

Thx a ton

Yes, I thought the change of none to null was probably a dead-duck, but I thought it was worth mentioning. It's worked for one of my clients (albeit not "null", but the language they needed was generic enough to make it look ok)

There's the hacks I mentioned searching for before - they aren't too huge, but do need a bit of understanding and a restart of Jira.

A third option might be a spot of javascript, which you can embed on the screen. You can use it to remove the "none" option, assuming you've added null/true/false as the three options. Not pretty, but doesn't require hefty coding. I think the behaviours plugin can do this for you too.

Suggest an answer

Log in or Sign up to answer
Community showcase

Scrum Roles Explained: the Do's and the Don'ts

Hello Community,  Today we are going to talk about the three Scrum Roles. There is the Development Team, the Scrum Master and the Product Owner. In my opinion these three are all really impo...

130 views 2 5
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you