I am unable to cut a line with the delimeter as a pipe symbol "|"
COuld you please help me ?
below is the code i am using right now
************
for i in `cat xyz`
do
source=`echo $i | cut -f 1 -d |`
echo $source
done
*********
Error i am recieving while exceuting the above scripts is as below where "abcd" is the above script name
./abcd: command substitution: line 2: syntax error: unexpected end of file
./abcd: command substitution: line 2: syntax error: unexpected end of file
The problem is solved..
I missed type the word "source" that is the reason it was giving a blank o/p
Now it is working fine..
source=`echo "$i" | cut -d '|' -f1`