[Durham] Fwd: interesting but expasperating problem sorting rows containing output from 'date' command [resend]

Dougie Nisbet dougie at highmoor.co.uk
Fri Aug 16 08:58:40 UTC 2013


---------- Forwarded message ----------
From: Dougie Nisbet <dougie at highmoor.co.uk>
Date: 16 August 2013 09:57
Subject: Re: [Durham] interesting but expasperating problem sorting rows
containing output from 'date' command [resend]
To: Martin Ward <martin at gkc.org.uk>



On 15 August 2013 17:54, Martin Ward <martin at gkc.org.uk> wrote:

> This seems to do what you want:
>
> sort -k9n,9n -k5M,5M -k6n,6n -k7,7
>

Thank you very much Martin, that does indeed work perfectly.

Funnily enough I'd understood that the -k option continued through the
remaining fields, but had I thought it through I'd have realised this was
going to cause a problem.

thanks again,

Dougie
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.lug.org.uk/pipermail/durham/attachments/20130816/0b76e22d/attachment.html>


More information about the Durham mailing list