Closed Bug 1004694 Opened 10 years ago Closed 10 years ago

Sort by ID in a bug list does not sort properly for 1000000+ bugs

Categories

(bugzilla.mozilla.org :: General, defect)

Production
defect
Not set
normal

Tracking

()

RESOLVED INCOMPLETE

People

(Reporter: mccr8, Assigned: dkl)

Details

If you open up a bug list, then click on the "ID" column to do a client side sort by ID, bugs with ids of 1000000+ are treated as being less than those of id 900000 or so.  It looks like it is doing a string sort instead of a sort as ints.
sorting a buglist by clicking on the 'id' column header is working for me.

:mccr8, would it be possible to provide a sample url where the bug list isn't sorted correctly?
Flags: needinfo?(continuation)
Hmm, weird, I'm only able to reproduce it on a few lists of all sec bugs.

Here's one:
https://bugzilla.mozilla.org/buglist.cgi?quicksearch=class%3Aclient%2Ccomp%20!sec-critical&list_id=10017151
Flags: needinfo?(continuation)
I see the failure when clicking on the link provided. I get the following output:

1000182
1000185
1001052
1001531
1001569
1002340
921622
963150
987679
988925
991533
991981
993768
995679
996715
999274
999759

and then the opposite:

999759
999274
996715
995679
993768
991981
991533
988925
987679
963150
921622
1002340
1001569
1001531
1001052
1000185
1000182

It is definitely a bug in the sorttable.js lib which handles the client side table sorting as the bug list starts of in the right order which happens in MySQL. Will take a look at how sorttable.js is doing the sorting for the bug id column.

dkl
Assignee: nobody → dkl
I haven't seen this in a while, because I haven't see any lists lately with sub-million bugs, and bug 1067381 fixed some sorting, so maybe that's fixed.  I'll reopen if I see it again.
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.