Bug 858965 - Target Milestones are not sorted correctly
Summary: Target Milestones are not sorted correctly
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Bugzilla
Classification: Community
Component: Query/Bug List
Version: 4.2
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Simon Green
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-09-20 08:15 UTC by Raymond Mancy
Modified: 2014-10-12 22:49 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-09-20 11:12:46 UTC
Embargoed:


Attachments (Terms of Use)

Description Raymond Mancy 2012-09-20 08:15:27 UTC
Description of problem:

The Target milestones select field is not sorted correctly.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1. Search for a Bug in beaker
2. Look at the Target Milestones after refreshing them
3.
  
Actual results:

0.10 comes before 0.6.1 etc etc

Expected results:

0.10 should be at the end

Additional info:

Comment 2 Raymond Mancy 2012-09-20 12:05:46 UTC
Are they not sorted ascending by default?

If so, it looks like a bug in the algorithm that thinks that 0.10.0 < 0.6.0

Comment 3 Simon Green 2012-09-20 20:51:52 UTC
(In reply to comment #2)
> Are they not sorted ascending by default?
> 
> If so, it looks like a bug in the algorithm that thinks that 0.10.0 < 0.6.0

Assuming the sort key is the same, they are sorted as a string by default (which explains why 0.10 < 0.6)

  -- simon

Comment 4 Raymond Mancy 2012-09-20 20:58:29 UTC
OK. Surely the _intent_ is to sort by ascending versions though yeah?
(at least for those strings that represent numbers, I realise there are some strings in there like 'future_maint' etc)

Comment 5 Simon Green 2012-09-20 21:13:48 UTC
(In reply to comment #4)
> OK. Surely the _intent_ is to sort by ascending versions though yeah?
> (at least for those strings that represent numbers, I realise there are some
> strings in there like 'future_maint' etc)

Nice to have, but MySQL doesn't support natural sorting, so I cannot see it happening. We have a sortkey on the table which is the correct solution around it.

Comment 6 Raymond Mancy 2012-09-20 21:39:07 UTC
Right, you would have to do it in bugzilla. Other apps can do it.
So manually sorting for every set of target milestones where it's not done correctly is the correct solution?

At least close it WONTFIX, rather than NOTABUG, as it clearly is a bug.


Note You need to log in before you can comment on or make changes to this bug.