We are coming from an AIX shop and new to Linux (Redhat)
we have a script example to show.
my shell looks like this
head $SCRIPTS/test1.txt | read parm1;
echo 'parm1=' $parm1
MYTESTVAR=`head $SCRIPTS/test1.txt`;
echo 'MYTESTVAR=' $MYTESTVAR;
test1.txt looks like this
This is a test
when I run the shell it produces this...
parm1=
MYTESTVAR= This is a test
When I run this in AIX, both parm1 AND MYTESTVAR both have the same value in them
What this tells me is that <somecommand> | read <somevariable> does not work
any ideas?
We already know some coding work-arounds but I was hoping not to have to change lots of my AIX shells but it does not look like I'll be that lucky.
Thanks in advance
Allen Lamb
[Email address protected]
Ochsner Clinic Foundation, New Orleans
504-842-7857
Oracle LazyDBA home page