Code:
/test/nigelp> awk -F, -f alg_awk_2 test.alg | sort -t, +3n
TEST:HOME,01010515,20061230204800,,0794,10,DIAG;
TEST:HOME,0102050A,20061230205838,,1094,10,DIAG;
TEST:HOME,01020518,20061230213158,,2844,10,DIAG;
TEST:HOME,01020502,20061230185622,,7397,10,DIAG;
TEST:HOME,01010513,20061230195958,,8721,10,DIAG;
TEST:HOME,0102051A,20061230201042,,8998,10,DIAG;
TEST:HOME,01020514,20061230202733,,9620,10,DIAG;