Use sqlplus command


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Use sqlplus command
# 1  
Old 08-09-2006
Use sqlplus command

Can someone tell me how to execute sqlplus command.

I`m Executing:
sqlplus user/pasw @/report/output/new/PlatformOut_Cdrs.sql

the error is:
SQL*Plus: Release 9.2.0.5.0 - Production on Wed Aug 9 15:37:44 2006

Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.

ERROR:
ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
HP-UX Error: 2: No such file or directory


Enter user-name:

---------------------
Please Help me.
Appreciate your reply
Smilie Smilie
# 2  
Old 08-09-2006
This means the instance of Oracle you are meant to use is not running. You need to contact your dba.
# 3  
Old 08-09-2006
or sqlplus doesn't see the instance that you are connecting to. Connect using sqlplus user/pasw@DATABASE ... or, alternatively, you can set your ORACLE_SID variable.
# 4  
Old 09-12-2006
sqlplus command

Hi all,
I am new to sqlplus, anyone can help me to explain what's the following code is doing?

DECLARE
cursor c1 is select bts_int_id,
max(ave_busy_tch/res_av_denom14) maxBusyTch
from p_nbsc_res_avail
where to_char(period_start_time,'yyyymmdd')=to_char((sysdate-1),'yyyymmdd')
group by bts_int_id;
BEGIN
FOR x IN c1 LOOP
update RNP_temp_table set
bts_id = x.bts_int_id,
max_busy_tch=x.maxBusyTch
where bts_id = x.bts_int_id;
IF SQL%NOTFOUND THEN
insert into RNP_temp_table
( bts_id,
max_busy_tch)
values
( x.bts_int_id,
x.maxBusyTch);
END IF;
COMMIT;
END LOOP;
COMMIT;
END;
/

Thanks in advanced.

Anthony
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. UNIX and Linux Applications

Problem on SQLplus command ""bash: sqlplus: command not found""

Hi all, i face an error related to my server ""it's running server"" when i use sqlplus command $ sqlplus bash: sqlplus: command not found the data base is up and running i just need to access the sqlplus to import the dump file as a daily backup. i already check the directory... (4 Replies)
Discussion started by: clerck
4 Replies

2. Shell Programming and Scripting

SQLPLUS command with more than 1 select statement

Hi all, I'm using below code processId=`sqlplus -s ${sysuser}/${syspwd} <<CHK_PROCESS whenever sqlerror exit sql.sqlcode; set head off feedback off echo off pages 0 SELECT PROCESS_ID FROM LSHADMIN.DATA_DOMAIN WHERE DOMAIN_NAME = '${tabname}' ... (8 Replies)
Discussion started by: Pratiksha Mehra
8 Replies

3. Shell Programming and Scripting

Sqlplus error - sqlplus -s <login/password@dbname> : No such file or directory

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)
Discussion started by: arghadeep adity
6 Replies

4. Shell Programming and Scripting

Can any one explain this sqlplus command?

Hi , i am new to unix i need a small clarification regarding this sqlplus -s $USER_NAME/$PASSWD@$ORA_SID<< EOF >> SQL_CONN_LOG.log In the above command what is the meaning of <<EOF>> Thanks, krishna. (2 Replies)
Discussion started by: rams_krishna
2 Replies

5. Shell Programming and Scripting

how to use sqlplus command inside for loop

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)
Discussion started by: deepakprasad29@
1 Replies

6. Ubuntu

sqlplus: command not found

I installed Oracle 10.2.1.0 in Ubuntu 10.10..my installation was well,i could even open isqlplus( http://ubuntu.ubuntu-domain:5560/isqlplus/workspace.uix ) and execute some queries..But,back in terminal when i try to login to sqlplus i am getting error (20 Replies)
Discussion started by: sandy0594
20 Replies

7. HP-UX

sqlplus: command not found

hi, i need bash shell script run on the crontab(Unix tru64). i have write my shell. it's using sqlplus command and connect to oracle db. execute cron job when i have error messege: "sqlplus: command not found" have you any suggestion? (4 Replies)
Discussion started by: Tlg13team
4 Replies

8. HP-UX

How to check sqlplus command is successfull or not in HP UX?

Hi All, I am not able to check the output of sqlplus command if it fails. can any body please help me in this regard. (5 Replies)
Discussion started by: plaban.rout
5 Replies

9. UNIX for Advanced & Expert Users

sqlplus and sh scripts (to_char command))

Hi evrybody!!!! I have a problem with this shell script INICIO=$(sqlplus -s user/user@db1 << END | awk '{printf $1}' set head off set feed off select to_char(min(create_dt) , 'HH24') from table_name where trunc(create_dt)=trunc(sysdate-2); END) I want to recover, in INICIO, the min... (4 Replies)
Discussion started by: josecollantes
4 Replies
Login or Register to Ask a Question