# stop the concurrent manager $COMMON_TOP/admin/scripts/$CONTEXT_NAME/adstpall.sh $DB_USER/$DB_PSWD # check if the processes are alive SPOOL_FILE="$APPLTMP/stop_cm_$TWO_TASK.tmp" while : ; do sqlplus -silent $DB_USER/$DB_PSWD << EOF spool $SPOOL_FILE select concurrent_queue_name, running_processes from fnd_concurrent_queues where running_processes > 0; spool off EOF egrep -q "no rows selected" $SPOOL_FILE RETURN_VALUE=$? if $RETURN_VAL1GUE -ne 0; then echo "Concurrent manager processes are still active. Sleeping for 10 seconds..." sleep 10 fi done rm $SPOOL_FILE echo "** Concurrent Manager and its processes are stopped **" if $RETURN_VAL1GUE -ne 0; then <<<< no rows selected ./stop_tst_db3_appl: line 34: -ne: command not found