[HPADM] Re: [HPADM-SUMMARY] who|awk '{print $1}'

From: Stephanie Chung (stepchung@yahoo.com)
Date: Tue Mar 15 2005 - 16:29:23 EST


Thanks all. It's really simple that I can't think of.
who|awk '{print $1}'|sort -u > file1.txt

Thank much.

Stephanie.

--- Erik Platzbecker <E.Platzbecker@ewi.tudelft.nl>
wrote:
> From Stephanie Chung;
> >
> > I want to get username who login and redirect to a
> > file. Here is the syntax which I use.
> >
> > who|awk '{print $1}' > file1.txt
> >
> > What I want is the file1.txt shows username one
> time
> > if that user login multiple session. Thanks for
> your
> > help.
> >
>
> hm, never heard of 'sort' ?
>
> who | awk '{print $1}' | sort -u > file1.txt
>
> will do the trick ...
>
> regards,
> --
>
----------------------------------------------------------------------------
> Erik Platzbecker |
> Phone: +31 (0)15-2783896
> A&I / Systems and Network Support |
> T.FAX: +31 (0)15-2781086
> Dept. of El.Eng., Math & Comp.Sci. (EWI) | room
> : LB 02.180
> Delft University of Technology |
> e-mail:
> PObox 5031, 2600 GA Delft, The Netherlands |
> E.Platzbecker@ewi.tudelft.nl
> -

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

--
             ---> Please post QUESTIONS and SUMMARIES only!! <---
        To subscribe/unsubscribe to this list, contact majordomo@dutchworks.nl
       Name: hpux-admin@dutchworks.nl     Owner: owner-hpux-admin@dutchworks.nl
 
 Archives:  ftp.dutchworks.nl:/pub/digests/hpux-admin       (FTP, browse only)
            http://www.dutchworks.nl/htbin/hpsysadmin   (Web, browse & search)


This archive was generated by hypermail 2.1.7 : Sat Apr 12 2008 - 11:02:46 EDT