Finder file sorting preferences - Finder ignores zero in filename

My issue, Finder and Matlab sort differently for files that have text and numbers in the name. Essentually I am viewing the Matlab output values side-by-side with the filenames from finder. Manual fixing this issue is NOT feasible given the volume of files I have (thousands).


Does anyone know how to change the default sort options so that Finder doesn't ignore them?!?!

Matlab Sort Order (and Desired Format)

Name03.dat

Name1.dat

Name2.dat

Name4.dat

Name8.dat


Finder Sort Order (Um... why?)

Name1.dat

Name2.dat

Name03.dat

Name4.dat

Name8.dat


(Please no general matlab advise)

OS X Mavericks (10.9.2)

Posted on May 4, 2014 7:52 PM

Reply
11 replies

Jul 23, 2016 6:32 AM in response to Reinard Schmitz

It is obviously an intentional design feature, not intended for people of our age and up close and personal experience with computers (punched my first 80-Column card around 1970, and have worked for Univac, DEC, Compaq, HP, and other companies big and small).


But Apple does not really target users with our experience.


If you want to tell Apple they are doing it wrong, then here are some links you can use:

BugReporter (Free ADC (Apple Developer Connection) account needed for BugReporter)

<http://bugreporter.apple.com>

Anyone can get a free ADC account at:

<https://developer.apple.com/register/index.action>

And/Or Mac OS X Feedback


<http://www.apple.com/feedback/macosx.html>

Most Applications in this world will fail to find a file with this logic.

Applications do not generally care about the Finder sort order. And if they ask the file system for a list of files, they are going to get them in an un-sorted order. The order returned will more likely be the order the files happened to be stored in the directory, which might be the order in which they were added to the directory, or if a hole from a previous file delete is large enough for the new file name, then inserted in the middle.

Jul 23, 2016 5:11 AM in response to Barney-15E

I started working with computers in 1970 (hardware construction and OS and Application programming) an did and do it all my life until now. Never i found an explanation like that. Most Applications in this world will fail to find a file with this logic. Its a bug. nothing more and nothing less. If it works for you thats ok., but it is a bug. For my work its a horror.


And my screenshot shows that it is sorted incorrectly and why I all the day am searching for a solution...

Jul 23, 2016 5:48 AM in response to Reinard Schmitz

It's not a bug. It is designed that way so you don't have to prepend padding characters to sort things numerically. You may not like it, but it has been that way since very early in the Mac OS.

Numbers in file names are almost exclusively used to add ordinality to the naming convention. Therefore, it makes perfect sense to sort the names based on that ordinal value.

Most humans don't think in this sense, "I will never need more than 640 files, so I will append two zeros at the front of my numerical suffixes. Oops, I need more than 1000 files, now. Crap..."

Nobody wants to see,

PO1

PO10

PO100

PO2

PO3

PO11

PO12

Jul 23, 2016 9:30 AM in response to Barney-15E

You are right. Nobody should see that, but:


P0001

P0002

P0021

P0234

P9999


So: If you have really 10 thousands of photos with the naming convention Pxxxxx.jpg and by mistake your workflow missed to transform the filename from the Camera (i.g. P3155.jpg to P03155.jpg) but the last file was P03154.jpg where would you search in a long finder list for the file? In the area of P0... or in that of P3... ?


The Finder sorts P03xxx and P3xxx to the same place in the list, so I will miss this file when I go to the P3... area.


I use Apple since 2003 and never ran in this problem, it just happened today for the 1st time. And I have to find a solution for this uncertainty.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Finder file sorting preferences - Finder ignores zero in filename

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.