Sort in AWK

Hi,
I usually use Access to sort data however for some reason its not working. Our systems guys and myself cannot figure it out so ive tried to use AWK to do the sorting. The file is made up of single lines in the format

L78-60/6:0-1480,195-1480,250-1552,500-1718,750-1862,1000-1985,1250-2102,1500-2235,1750-2406,2000-2600,2250-2763,2500-2907,2750-3086,3000-3310,3250-3496,3500-3661,3750-3789/
L76-37/24:0-1480,71-1480,250-1654,500-1857,750-2003,1000-2144,1250-2388,1500-2636,1750-2780,2000-2884,2250-3129,2500-3372,2750-3547,3000-3675,3250-3773,3500-3851,3750-3928/
L76-28/24:0-1480,54-1480,250-1717,500-1813,750-1964,1000-2101,1250-2234,1500-2399,1750-2556,2000-2684,2250-2843,2500-3034,2750-3171,3000-3300,3250-3409,3500-3585,3750-3794/

I have been using sort -n to sort by 1st field (FS= /) but I can get nothing.

Can anybody help?

Thanks :slight_smile:
Ryan

sort -t '/' -k1,1 myFile

Thanks Vgersh99!

I usually use a command line of

gawk.exe -f filter.awk vel.txt  > filtered_file.txt

How would I use your suggestion in this way? I have played about with the code but only nonsensical results are output to filtered_file.txt

Thanks again

Ryan

I guess I don't understand why you need to use 'gawk' to do the sorting.
Just use a plain/old 'sort' - no need for gawk/awk.

Sorry but I have no idea how to sort without gawk (I also have almost no knowledge of how to use gawk). From what I have read, I thought it would be simple to use. Is it not possible to modify

sort -t '/' -k1,1 myFile

to run using my command line.

Apologies again. I have learnt alot about gawk since I started but still along way to go. I have no idea about any other unix commands so really just trying to get the grips with AWK for now