#!/usr/bin/csh

# do_web_sql.csh

# Start up sqlplus and execute the sqlplus commands contained in the
# command passed as the third argument.  The first argument
# contains the sqlplus program to execute. The second argument
# contains the SQLPLUS login information.  This routine attemps to
# set up the environment required by sqlplus.  So the command
# is called as
# 	do_web_sql.csh /u01/app/oracle/product/8.0.5/bin/sqlplus
#		groman/jgofs@ORC1 sqlcommands.sql

# November 17, 1998  rcg

set version="17Nov1998/1.00"
#echo "do_web_sql.csh, $version"

set command="$argv[1]"
set login="$argv[2]"
set filespec="$argv[3]"

#echo "command=$command"
#echo "login=$login"
#echo "filespec=$filespec"

set path = (/usr/bin /u01/app/oracle/product/8.0.5/bin)

# SQLPLUS environment variables and :
setenv ORACLE_BASE /u01/app/oracle
setenv ORACLE_HOME /u01/app/oracle/product/8.0.5
setenv ORACLE_SID glbc
setenv ORACLE_TERM vt100
set ORAENV_ASK = NO
source /usr/local/bin/coraenv

$command "-SILENT" $login $filespec

