Sorting lines

runrev260805 at m-r-d.de runrev260805 at m-r-d.de
Tue May 29 13:14:07 EDT 2007


Hi, 

i have textfile, which contains data. Each line of this text file contains serveral values, which are separated by ;.
Each line has the  same number of values. My problems is, that i have to sort the lines by one of the values, in this case by the value of the 4th field.


My textfile looks something like this. There are about 42 fields per line.

320;4999;219,Peter;329;366
1000;999;10101;Mark;211;555
2;214;25;Peter;212:667
2;213;13;Josh;215;666
3;23;14;Mark;0;0
and so on


I have to sort the textfile by the 4th value (the names). I need all lines with the same name in field4 one below the other - similar like this:

2;213;13;Josh;215;666
3;23;14;Mark;0;0
1000;999;10101;Mark;211;555
2;214;25;Peter;212:667
320;4999;219,Peter;329;366

How should i solve this? 

I hope i described it a little understandable.

Regards,

Matthias





More information about the use-livecode mailing list