#!/bin/csh -f

echo "====================================================================================================================="
echo `date` "----> " " Started"
echo "====================================================================================================================="

set EXIT_CODE = 0

cd $DATA_DIR

$SQL_HOME/sqlplus -s / << EOF
 WHENEVER OSError  EXIT FAILURE;
 WHENEVER SQLError EXIT FAILURE;
 exec Oracle_Schema.packag_name.procedure_name('$argv[1]');
EXIT SUCCESS;
EOF

if ( $status != 0 ) then
   echo "Failed "
   set EXIT_CODE = 1
else
   echo "Procedure Successfully Completed"
endif
   
echo "====================================================================================================================="
echo `date` "----> " "Completed"
echo "====================================================================================================================="
exit $EXIT_CODE
