Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Get hostname of Oracle Server from within SQLPlus

Re: Get hostname of Oracle Server from within SQLPlus

From: Michel Cadot <micadot_at_netcourrier.com>
Date: Mon, 30 Jul 2001 17:10:07 +0200
Message-ID: <9k3tcg$jf6$1@s1.read.news.oleane.net>

"steve" <lmcstmc_at_lmc.ericsson.se> a écrit dans le message news: bdd5c887.0107300621.7fae68d5_at_posting.google.com...
> Hi,
>
> Is there a SQL command I can issue from within SQLPlus
> that will return the hostname of the Oracle Server I
> am currently connected to (assuming it is a remote server).
>
> Something along the lines of 'select name from v$database;'
>
> Thanks.
>
> Steve

I used:
select machine from v$session where type='BACKGROUND' and rownum=1; for years.
Now, there is:
select host_name from v$instance;

--
Have a nice day
Michel
Received on Mon Jul 30 2001 - 10:10:07 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US