Hi,
Can somebody point me why I get "expression syntax error" for the following Korn shell script?
I am not initializing x, y, z.
Can somebody point me why I get "expression syntax error" for the following Korn shell script?
Code:
x=`awk '/Info: .*.abc/{print $2}' results.log`
y=`awk '/Info: .*.txt/{print $2}' results.log`
z=`awk '/Total: /{print $2}' results.log`
if [ $x == $z ];
then
echo "match" >> grep.txt
else
echo "does not match" >> grep.txt
fi
I am not initializing x, y, z.