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
9 More Discussions You Might Find Interesting
1. UNIX for Advanced & Expert Users
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
2. 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
3. HP-UX
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
4. Ubuntu
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
5. Shell Programming and Scripting
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. Shell Programming and Scripting
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
7. Shell Programming and Scripting
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
8. Shell Programming and Scripting
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
9. UNIX and Linux Applications
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
LEARN ABOUT PHP
oci_set_client_info
OCI_SET_CLIENT_INFO(3) OCI_SET_CLIENT_INFO(3)
oci_set_client_info - Sets the client information
SYNOPSIS
bool oci_set_client_info (resource $connection, string $client_info)
DESCRIPTION
Sets the client information for Oracle tracing.
The client information is registered with the database when the next 'roundtrip' from PHP to the database occurs, typically when an SQL
statement is executed.
The client information can subsequently be queried from database administration views such as V$SESSION.
The value may be retained across persistent connections.
PARAMETERS
o $connection
-An Oracle connection identifier, returned by oci_connect(3), oci_pconnect(3), or oci_new_connect(3).
o $client_info
- User chosen string up to 64 bytes long.
RETURN VALUES
Returns TRUE on success or FALSE on failure.
EXAMPLES
Example #1
Setting the client information
<?php
$c = oci_connect('hr', 'welcome', 'localhost/XE');
// Record the client information
oci_set_client_info($c, 'My Application Version 2');
// Code that causes a roundtrip, for example a query:
$s = oci_parse($c, 'select * from dual');
oci_execute($s);
oci_fetch_all($s, $res);
sleep(30);
?>
// While the script is running, the administrator can see the client
// information:
sqlplus system/welcome
SQL> select client_info from v$session;
NOTES
Note
Oracle version requirement
This function is available when PHP is linked with Oracle Database libraries from version 10 g onwards.
Tip
Performance
With older versions of OCI8 or the Oracle Database, the client information can be set using the Oracle DBMS_APPLICATION_INFO pack-
age. This is less efficient than using oci_set_client_info(3).
Caution
Roundtrip Gotcha
Some but not all OCI8 functions cause roundtrips. Roundtrips to the database may not occur with queries when result caching is
enabled.
SEE ALSO
oci_set_module_name(3), oci_set_action(3), oci_set_client_identifier(3).
PHP Documentation Group OCI_SET_CLIENT_INFO(3)