Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!swrinde!elroy.jpl.nasa.gov!lll-winken!sun-barr!newstop!central!convex!mic!ernest!shibaya!afc From: afc@shibaya.lonestar.org (Augustine Cano) Newsgroups: comp.unix.shell Subject: SUMMARY & THANKS Re: How to read sequentially from a file in SH Message-ID: <1991May13.183312.23176@shibaya.lonestar.org> Date: 13 May 91 18:33:12 GMT Organization: Multidisciplinary Designs Unlimited Lines: 29 Many thanks to all who responded to my question, both by e-mail and follow-ups. There were a few posted follow-ups, so I won't re-hash those. Some e-mail respondents indicated that some versions of sh do in fact work as ksh does. ie: while read VAR1 VAR2 < $FILENAME; do echo $VAR1 $VAR2 done However, what did work even with my sh was the following: while read VAR1 VAR2; do echo $VAR1 $VAR2 done < $FILENAME Also, Hans Mulder (hansm@cs.kun.nl) says that on SunOS 4.1.1 this works: exec 3< $FILENAME while read VAR1 VAR2; do echo $VAR1 $VAR2 done <&3 Thanks again to all who responded. -- Augustine Cano INTERNET: afc@shibaya.lonestar.org UUCP: ...!{ernest,egsner}!shibaya!afc