Details
-
Bug
-
Resolution: Unresolved
-
Medium
-
None
-
5.2.4.1, 6.3.15, 6.4.11, 7.13.1, 8.2.4, 8.5.6, 8.13.1, 8.21.0, 9.10.0
-
5.02
-
34
-
Severity 2 - Major
-
14
-
Description
NOTE: This bug report is for JIRA Server. Using JIRA Cloud? See the corresponding bug report.
Summary
By default Jira ships with settings to accept only 2 digits for year values in dates. This causes ambiguity for dates of events that are several years in the future or past because of the inherit loss of precision that comes with trying to store a four digit value like a year with only two digits.
Steps to reproduce:
- Create or edit an issue and set the Due Date to 12/31/2031 or any date after that.
Expected behavior:
Jira should set the correct date.
Actual results:
You pick a date after 12/31/2031 it will yield a date from early 1900's.
For example, picking 12/31/2032 yields 12/31/1932 when the field is saved.
Workaround:
A Jira Administrator can change the input settings and the look and feel setting so that all dates in Jira will always use 4 digit years instead of 2 digit years. This will help to avoid the problem when users are setting values going forward.
1. ⚙︎ -> System -> General configuration -> Advanced settings:
Change 4 values on this page
- jira.date.picker.java.format
- jira.date.picker.javascript.format
- jira.date.time.picker.java.format
- jira.date.time.picker.javascript.format
For the java fields change the 'yy' portion to 'yyyy'. For the javascript entries, the syntax is different, you have change '%y' to '%Y'. So for example if jira.date.picker.java.format has a current value of 'd/MMM/yy' (without quotes) you would change this to 'd/MMM/yyyy'.
2. ⚙︎ -> System -> User Interface -> Look and Feel
The look and feels settings also need to be updated. Change the year values here from 'yy' to be 'yyyy'.
Attachments
Issue Links
- is duplicated by
-
JPOSERVER-10873 Target Start and Target End field showing incorrect dates when date is set after 31 Dec 2029
- Closed
-
JRASERVER-45192 JIRA - year 2030 in the Date / Date time picker customfield become 1930
- Closed
- is related to
-
JRASERVER-71491 Jira should store all dates that contain years with 4 digits of precision, and not just 2 digits
- Gathering Interest
- relates to
-
JRACLOUD-31291 JIRA Date Picker not working for dates after 2031
- Closed
-
JRACLOUD-72814 Selecting a date from 2030 and the following years converts the year to 19xx
- Closed
-
JRASERVER-20007 Default date format is two-digit and loses century chosen in calendar picker
- Gathering Impact
-
JRASERVER-65762 Creating issue with invalid date format will still create issue even though error is thrown
- Gathering Impact
-
JRASERVER-71354 Using date picker custom field with the format “YYYY/MM/DD”, and setting a date after 2039 using API call, automatically changes the year to 19XX.
- Gathering Impact