Add the following to your login.sql or glogin.sql file:

 

set serveroutput on

set termout off

column instance new_value prompt_instance

select substr(instance_name, 1, 10)instance

from v$instance

/

set sqlprompt "&&prompt_instance> "

set termout on

 

 

HTH,

 

david

 

David B. Wagoner

Database Administrator

Arsenal Digital Solutions Worldwide Inc.

4815 Emperor Blvd., Suite 110

Durham, NC 27703

Tel. (919) 941-4645

Fax (919) 474-0735

Email mailto:[EMAIL PROTECTED]

Web http://www.arsenaldigital.com/

 

                                                                                                          ***  NOTICE  ***

This e-mail message is confidential, intended only for the named recipient(s) above and may contain information that is privileged, work product or exempt from disclosure under applicable law.  If you have received this message in error, or are not the named recipient(s), please immediately notify the sender at (919) 941-4645 and delete this e-mail message from your computer.  Thank you.

 

-----Original Message-----
From: Ramon Estevez [mailto:[EMAIL PROTECTED]]
Sent: Thursday, October 25, 2001 10:35 AM
To: Multiple recipients of list ORACLE-L
Subject: Instance Name in Sql Prompt

 

Hi Friends,

 

Excuse me for this dumb question,  how do I display the instance name in the

sql prompt.  Have 3 DB and would like to know to which one I am connected.

 

I mean something like that.

 

DBA1 >

DBA2 >

DB01 >

 

Regards,

 

Ramon E. Estevez

[EMAIL PROTECTED]

Dominican Republic

809-565-3121

 

Reply via email to