Hi Guys,
This is my code of if else if
echo "length=$length";
echo $fun_RTYPE;
if [ "$length" -eq "1" ] -a [ "$fun_RTYPE" -eq "RW" ]
then
VALUE_V=$(echo "scale=4; $VALUE_V * $child_value" | bc);
echo "value_outer=$VALUE_V";
else if [ "$length" -eq "1" ] -a [ "$fun_RTYPE" -eq "RP" ]
then
level_new=`expr $level_new + 1`;
VALUE_RP=`expr $VALUE_V / 100`;
echo "value_inner=$VALUE_V";
#echo $VALUE_RP;
function_recur $TOP_ID $FATHER_ID $level_new $VALUE_RP;
fi
fi
This is from the log of the script.
length=1 RP value_outer=45.000000
Even though the length is 1 and RTYPE is RP. It is not going in the second if part..
Please correct me where i am going wrong.
Thanks for your help in advance.
Regards,
Magesh.