The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM


Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
for loop in unix deep_kol Shell Programming and Scripting 1 04-29-2008 07:39 AM
option followed by : taking next option if argument missing with getopts gurukottur Shell Programming and Scripting 2 03-17-2008 08:46 AM
Print Problem in UNIX. Need to know the option to specify the print paper size ukarthik HP-UX 1 06-07-2007 06:35 AM
UNIX chauthtok(): illegal module option stancwong UNIX for Dummies Questions & Answers 1 01-19-2006 12:20 AM
Please help with UNIX while loop... gerard1 Shell Programming and Scripting 1 02-01-2005 08:39 AM

Reply
 
Submit Tools LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 05-19-2008
Registered User
 

Join Date: Feb 2008
Posts: 13
what is -u option in while loop in unix

Hi all,

What does -u option in while loop indicates in unix?

ex: while read -u field
Reply With Quote
Forum Sponsor
  #2 (permalink)  
Old 05-19-2008
agn agn is offline
Registered User
 

Join Date: Feb 2008
Posts: 97
-u is a flag to 'read', not while. See your shell's man page to find what it does. In ksh -u should be followed by a file descriptor (ex: read -u3). It causes input to be read from the specified file descriptor (3 in the above example). -u without a file descriptor defaults to 0 - the standard input. You can also omit -u if reading from stdin.
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 06:26 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Global Fact Book

Content Relevant URLs by vBSEO 3.2.0