INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Sorting by filename when using a numeric prefix  (Read 2218 times)

mc_user

  • Member
  • *
  • Posts: 4
Sorting by filename when using a numeric prefix
« on: April 26, 2010, 07:39:22 am »

I've got a number of mp3 files with a numeric prefix.  When I sort by file name the prefix seems to be ignored, so "0005-A.mp3" will come before "0003-D.mp3" 

I also created an expression column with just the prefix, but clicking on the column name doesn't seem to sort it (though it says it does). 

Any help getting either to work would be appreciated; I'd prefer the first to work since it's native to the application, but getting the expression to sort properly would be an acceptable workaround.
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42373
  • Shoes gone again!
Re: Sorting by filename when using a numeric prefix
« Reply #1 on: April 26, 2010, 10:59:30 am »

Is it possible the paths are different for the two files you're comparing?

Assuming the paths are the same, the numeric prefix should be sorted as a numbers (so 5 comes before 10, etc.)

Maybe make a playlist of the files and sort the playlist to rule out the view doing any fancy processing.

Let us know what you find.  Thanks.
Logged
Matt Ashland, JRiver Media Center

mc_user

  • Member
  • *
  • Posts: 4
Re: Sorting by filename when using a numeric prefix
« Reply #2 on: April 26, 2010, 11:25:33 am »

All are in the same directory, and it behaves the same when I put them in a playlist.  I've got a screen shot attached - you can see the numeric prefix as well as how it is sorting alphabetically.
Logged

gappie

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 4580
Re: Sorting by filename when using a numeric prefix
« Reply #3 on: April 26, 2010, 11:30:10 am »

maybe a small thing to check, just to be sure.
are the 0000
all zero's or is there a capital o somewhere?
had that happen ones.

 :)
gab
Logged

mc_user

  • Member
  • *
  • Posts: 4
Re: Sorting by filename when using a numeric prefix
« Reply #4 on: April 26, 2010, 01:08:02 pm »

Here is how it lists (truncated) from the command prompt:

20100413142130-Ad
20100414144309-Go
20100414144558-Wu
20100415144559-Sw
20100415144560-at
20100420102411-Av
20100420102520-B.
20100420102618-Bl
20100420102707-Co
20100420102941-JY
20100420103432-Ke
20100420103541-Lo
20100420103621-Pa
20100420103650-Vi
20100420103715-Th
20100420103750-An
20100420103941-Jo
20100420104039-al
20100420104122-Fi
20100420104124-al
20100420104126-Wa

Here's how it sorts in MC 15:

20100413142130-Ad
20100420104039-al
20100420104124-al
20100420103750-An
20100415144560-at
20100420102411-Av
20100420102520-B.
20100420102618-Bl
20100420102707-Co
20100420104122-Fi
20100414144309-Go
20100420103941-Jo
20100420102941-JY
20100420103432-Ke
20100420103541-Lo
20100420103621-Pa
20100415144559-Sw
20100420103715-Th
20100420103650-Vi
20100420104126-Wa
20100414144558-Wu

It should sort the first way (as far as I can tell).  See anything wrong?
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42373
  • Shoes gone again!
Re: Sorting by filename when using a numeric prefix
« Reply #5 on: April 26, 2010, 03:39:22 pm »

The smart number handler that makes 5 come before 10 (even though 5 sorts before 1 alphabetically) only handles up to 32-bit integers.

Those big numbers you're using are overflowing it.  We'll look at expanding this to 64-bit in a coming build.
Logged
Matt Ashland, JRiver Media Center

mc_user

  • Member
  • *
  • Posts: 4
Re: Sorting by filename when using a numeric prefix
« Reply #6 on: April 27, 2010, 06:50:01 am »

OK, thanks.  FYI, I just upgrade from MC 11 and that one handled it fine.
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42373
  • Shoes gone again!
Re: Sorting by filename when using a numeric prefix
« Reply #7 on: April 28, 2010, 03:51:34 pm »

Logged
Matt Ashland, JRiver Media Center
Pages: [1]   Go Up