From owner-freebsd-questions Thu Jun 28 11:42:54 2001 Delivered-To: freebsd-questions@freebsd.org Received: from comp1.mastery.ca (comp1.mastery.ca [209.202.88.60]) by hub.freebsd.org (Postfix) with ESMTP id C7A5437B40D for ; Thu, 28 Jun 2001 11:42:50 -0700 (PDT) (envelope-from rmasse@mastery.ca) Received: from 78kw954 ([209.202.88.150]) (authenticated) by comp1.mastery.ca (8.11.3/8.11.1) with ESMTP id f5SIgcQ06175; Thu, 28 Jun 2001 14:42:38 -0400 (EDT) (envelope-from rmasse@mastery.ca) Message-ID: <016b01c10002$17fd5ee0$3200000a@Intranet> From: "Ryan Masse" To: "Philip Hallstrom" Cc: "FreeBSD-Questions" References: <20010628110020.T16401-100000@oddjob.adhesivemedia.com> Subject: Re: OT: awk help Date: Thu, 28 Jun 2001 14:42:33 -0400 X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG it didn't dawn on me to use the '&&' =\ anyhow thanks to those that responded Ryan > Try... > > awk -F: '$3 >= 1001 && $3 <= 65500 { print $1 }' /etc/passwd > > On Thu, 28 Jun 2001, Ryan Masse wrote: > > > i'm not to fimiliar with awk but i want to rip through /etc/passwd and print > > out to file all users greater than uid 1001 and less than 65500. I've come > > up with this so far; > > > > awk -F: '$3 > 1001 { print $1 }' /etc/passwd > /var/db/user.db > > > > i can't seem to create a statement that will printout both the lbount and > > ubound of 1001 and 65500 > > > > can someone lend me their thinking cap? > > > > Ryan > > > > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > > with "unsubscribe freebsd-questions" in the body of the message > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message