Error with nested if within an sqlplus task inside
Hi ALL,
I am receving a "strange" error using a nested if within an sql operation inside:
./dom.ksh[71]: syntax error at line 80 : `then' unmatched
This is all my script code: in bold the step receiving the error.
Any help would really aprrecieted ......!
**** I have tried all the possible syntax also consulting other forum discussions about shells script but unfortunately without success ........
if [[ $SKIP_ARBOR = skipArbor ]]
if [ $SKIP_ARBOR = skipArbor ]
if [[ "$SKIP_ARBOR" = "skipArbor" ]]
if [ ${SKIP_ARBOR} = skipArbor ]
if [ "${SKIP_ARBOR}" = "skipArbor" ]
if [ "${SKIP_ARBOR}" = skipArbor ]
etc .......
Operating System: HP-UX B.11.31 U 64 bit ia64
Tks in advance.
I have a file contains
TASK gsnmpproxy {
CommandLine = $SMCHOME/bin/gsnmpProxy.exe
}
TASK gsnmpdbgui {
CommandLine = $SMCHOME/bin/gsnmpdbgui.exe
I would like to comment and than uncomment specific task eg TASK gsnmpproxy
Pls suggest how to do in shell script (9 Replies)
I have a question about nested double quotes. Any help is appreciated.
Here are my commands on Mac OS.
# string="Ethernet \"USB Ethernet\" \"Bluetooth DUN\" AirPort FireWire \"Bluetooth PAN\""
# echo $string
Ethernet "USB Ethernet" "Bluetooth DUN" AirPort FireWire "Bluetooth PAN"
#... (3 Replies)
Hi all,
I am using the below given sqlplus command in my unix script to invoke a stored procedure which returns a value .It works fine.
RET_CODE=$(/opt/oracle/product/10.2.0.4.CL/bin/sqlplus -S $USER/$PASSWD@$DB_NAME <<EOF
EXEC MY_PKG.MY_SP (:COUNT);
PRINT COUNT;
commit;
... (6 Replies)
Hello,
I need to repack a file inside several java archives (nested .jar files) with or without overwrite.
I am using a manual approach with mc, but it's painfully slow progress.
For example I want to refresh a file deep inside a java archive (with nested .jar files):
I have a java... (0 Replies)
I tried this:
for region in 'raj' 'kt' 'kol' 'krl' 'chn' 'dl' 'hr' 'bih' 'ap'
do
sqlplus -s huw$region/`echo $region`huw#321@huw$region<<!
set serveroutput on
begin
select count(*) from tcd_preferred_cust_201109
end;
/
exit;
done
but the error shows like:
Syntax error at line 4 :... (1 Reply)
HI everyone,
I am not able to find error in the script, when i run the script till
line No. 20
i.e, read var4
everything runs fine. After that the script exits out.
#!/bin/bash
echo -e "Want dryrun OR merge: \n "
read var1
if ] ; then
echo -e "\n Please select from the given... (10 Replies)
please let me know if the below code could be written efficiently inside single awk
case "$INP" in
ksh)
cat catalog | awk 'BEGIN {FS=",";} { print $2 } END {}'
;;
pset)
cat catalog | awk 'BEGIN {FS=",";} { print $3 } END {}'
;;
dml)
cat catalog | awk 'BEGIN {FS=",";} {... (2 Replies)
Hello,
I have a problem. I want to launch a different sql queries for different shell parameter values, something like this.
#/bin/bash
case $1 in
"A")
sqlplus -s user/pass << SQL
query A;
SQL
"B") sqlplus -s user/pass << SQL2
... (3 Replies)
Hi,
facing an issue while calling sqlplus inside shell script. It for some reason goes to tmp file to write something and i get error as permission denied as i dont have access there.
ANy idea why sqlplus writes in /tmp and how to change or stop this ? (2 Replies)
i am using bash shell
Whenever i declare an array, and then using sqlplus, i am getting sqlplus error and return code 127.
IFS=","
declare -a Arr=($Variable1);
SQLPLUS=sqlplus -s "${DBUSER}"/"${DBPASS}"@"${DBASE}
echo "set head off ; " > ${SQLCMD}
echo "set PAGESIZE 0 ;" >> ${SQLCMD}... (6 Replies)