Avatar of rlburris
rlburris

asked on 

Need help with "sort" command

What would be the sort command if I wanted to sort the file by the last field (the fifth field)?

File sample:

,040606,20040401,            ,123456789,362 |
                                                           ^
                                                            |
                                                            |
                                                     This field
Unix OS

Avatar of undefined
Last Comment
rlburris
ASKER CERTIFIED SOLUTION
Avatar of fim32
fim32

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of rlburris
rlburris

ASKER

Thanks... the command was:

sort input.name -n -t, -k 5 -o output.name
Unix OS
Unix OS

Unix is a multitasking, multi-user computer operating system originally developed in 1969 at Bell Labs. Today, it is a modern OS with many commercial flavors and licensees, including FreeBSD, Hewlett-Packard’s UX, IBM AIX and Apple Mac OS-X. Apart from its command-line interface, most UNIX variations support the standardized X Window System for GUIs, with the exception of the Mac OS, which uses a proprietary system.

33K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo