From com.banilejas@codetel.net.do Thu, 25 Oct 2001 12:08:11 -0700 From: "Ramon Estevez" Date: Thu, 25 Oct 2001 12:08:11 -0700 Subject: RE: Instance Name in Sql Prompt Message-ID: MIME-Version: 1.0 Content-Type: text/plain Thanks to Kevin and all that reply.   I noticed when doing a connect inside a session.   This will help.   Ramon E. Estevez com.banilejas@codetel.net.do Dominican Republic 809-565-3121 -----Mensaje original-----De: root@fatcity.com [mailto:root@fatcity.com]En nombre de Kevin LangeEnviado el: Thursday, 25 October, 2001 11:10 AMPara: Multiple recipients of list ORACLE-LAsunto: RE: Instance Name in Sql Prompt Ramon;   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 onset pagesize 0set echo offset feedback offset sqlprompt ''spool c:\temp.sqlselect 'set sqlprompt '''||name||' > '';' from v$database;spool off@c:\temp.sqlset pagesize 35set feedback onset termout off What 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 to   INSTANCE_NAME >   where INSTANCE_NAME is the name of the database.   For example, if I log onto DEV then the SQLPROMPT will be   DEV >   Hope you can use it.   Kevin   p.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:com.banilejas@codetel.net.do]Sent: Thursday, October 25, 2001 9:35 AMTo: Multiple recipients of list ORACLE-LSubject: 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 com.banilejas@codetel.net.do Dominican Republic 809-565-3121