On 05-Jul-2005 Justin Pryzby wrote: >> $ echo Hello, world | read a b; echo $a $b >> > I believe the reason is this (from sh(1)): > > Each command in a pipeline is executed as a separate process > (i.e., in a subshell). > > ... > > A command invoked in this separate environment cannot > affect the shell's execution environment. > > It will work if you use read <<EOF ...
Thanks, Justin. You're quite right - as so often happens, Matthias's terse comment caused the penny to drop big time and leave me feeling somewhat foolish. I have since worked out how to make the offending script (normal environment ksh on AIX) bash-friendly. -- Jim Hague - [EMAIL PROTECTED] Never trust a computer you can't lift. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]