in reply to how do I sort numerically on sections of data that is alphanumeric
Folks, first of all I would like to thank everyone who replied. Its brought me a long way in understanding how sorting can work in different ways. Some of them were a little advanced for a newbie :)
I thought I'd explain the whole thing:
The data is being read in from a file. I thought the easiest way to sort it this way would be to read it into an array first and then figure out a way to sort it like I had explained earlier.
The layout of the data remains consistent and the numbers are always zero-padded.
I want to sort using the numbers in the second column and then the numbers in the third column. The A in the third column needs to stay there but that column needs to be sorted using the numbers.
Once the array is sorted I write it back to a file.
I don't know if this was the simplest way of doing it, but thats how I wanted to go about it.
Once again thanks all for the help!
shaezi