Thanks to
Kevin and all that reply.
I noticed
when doing a connect inside a session.
This will
help.
Ramon E.
Estevez
Dominican Republic
809-565-3121
-----Mensaje original-----
De: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]En nombre de Kevin Lange
Enviado el: Thursday, 25 October, 2001 11:10 AM
Para: Multiple recipients of list ORACLE-L
Asunto: RE: Instance Name in Sql PromptRamon;In your startup directory on SQL Plus, you can automatically run a script that will setup the environment like you want it. Its called LOGIN.SQL.Here is a copy of mine:set termout on
set pagesize 0
set echo off
set feedback off
set sqlprompt ''
spool c:\temp.sql
select 'set sqlprompt '''||name||' > '';' from v$database;
spool off
@c:\temp.sql
set pagesize 35
set feedback on
set termout offWhat this does is to take the name of the database from v$database and create a temporary SQL file, then runs it. This will set my prompt toINSTANCE_NAME >where INSTANCE_NAME is the name of the database.For example, if I log onto DEV then the SQLPROMPT will beDEV >Hope you can use it.Kevinp.s. ... Remember that this only works for the initialization of SQL Plus. If you do a connect inside of your session then the prompt will not change.-----Original Message-----
From: Ramon Estevez [mailto:[EMAIL PROTECTED]]
Sent: Thursday, October 25, 2001 9:35 AM
To: Multiple recipients of list ORACLE-L
Subject: Instance Name in Sql PromptHi Friends,Excuse me for this dumb question, how do I display the instance name in thesql 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. EstevezDominican Republic809-565-3121
