AWK question

Ken Turkowski ken at turtlevax.UUCP
Thu Aug 8 03:10:32 AEST 1985


In article <435 at brl-tgr.ARPA> ddaly%xls-plexus01.amc at AMC-HQ.ARPA (DUSTY) writes:
>Does anyone know if and how I can get awk to do a >= (less than or equal)
>on a value entered from a terminal by the user?
>E.G.
>echo 'enter date in format yy-mm-dd \c $dt'
>read  dt
>echo $dt
>awk '$5  >= $dt ' .suspfile >xout

Have you tried using double quotes instead of single quotes? Try:
	awk "$5  >= $dt " .suspfile >xout
-- 

Ken Turkowski @ CADLINC, Menlo Park, CA
UUCP: {amd,decwrl,hplabs,nsc,seismo,spar}!turtlevax!ken
ARPA: turtlevax!ken at DECWRL.ARPA



More information about the Comp.unix.wizards mailing list