Hi,
I am using solaris 5.10 environment and need help on doing parallel increment of nested for loop.
Samples
#inside the code the values assigned to a variable by another awk command will be like
a=/xyz/pg/as
/xyz/pg/as2
/xyz/pg/as3
b=/xyz/sd/fd1
/xyz/sd/fd2
/xyz/sd/fd3
for q in ${a[@]}; do
for p in ${b[@]}; do
LName=`find "$p" -name *"$x".txt -type f |sort | head -1`
if [ "$LName" != "" ]; then
break
fi
done
done
definitely there will be equal amount of records in both variable a & b. based on the file availability in the corresponding path in variable b, i need to choose the corresponding path from variable a.
say for example *"$x".txt file was available in the path /xyz/sd/fd3 (3rd iteration) i need to choose the corresponding path (/xyz/pg/as3) from variable a for further processing.
cFile=`find "$q" -name *.log -type f |sort | head -1`