RE: how can I see which database I am logged into without

2003-09-12 Thread Paul Baumgartel
Mladen, doesn't your spell checker dictionary include
"RUMPELSTILTSKIN"?

;-)

--- Mladen Gogala <[EMAIL PROTECTED]> wrote:
> How about:
> 
> SELECT 'RUMPELSTILSKIN' FROM DUAL;
> 
> That should be a good guess.
> 
> --
> Mladen Gogala
> Oracle DBA 
> 
> 
> 
> > -Original Message-
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On 
> > Behalf Of Jose Luis Delgado
> > Sent: Thursday, September 11, 2003 4:38 PM
> > To: Multiple recipients of list ORACLE-L
> > Subject: RE: how can I see which database I am logged into without
> > 
> > 
> > Can you try:
> > 
> > select global_name from global_name;???
> > 
> > compare it with your 
> > select ora_database_name from dual
> > 
> > Are they the same?
> > 
> > HTH
> > JL
> > 
> > --- David Wagoner <[EMAIL PROTECTED]> wrote:
> > > You might get some surprising results from SELECT
> ORA_DATABASE_NAME 
> > > FROM DUAL; (see below).  I have a DEV database cloned
> > > from Prod. and it still
> > > lists the Prod. DB name with that query.  Where is
> > > it reading the name from?
> > > You can see that other queries produce the "correct"
> > > name.
> > > 
> > > 
> > > SQL> select instance_name from v$instance;
> > > 
> > > INSTANCE_NAME
> > > 
> > > dmedi01
> > > 
> > > SQL> show parameter name;
> > > 
> > > NAME TYPE   
> > > VALUE
> > >  ---
> > > --
> > > db_file_name_convert string
> > > db_name  string 
> > > dmedi01
> > > global_names boolean
> > > FALSE
> > > instance_namestring 
> > > dmedi01
> > > lock_name_space  string
> > > log_file_name_convertstring
> > > oracle_trace_collection_name string
> > > oracle_trace_facility_name   string 
> > > oracled
> > > plsql_native_make_file_name  string
> > > service_namesstring 
> > > dmedi01.arsenaldigital.com
> > > 
> > > SQL> select ora_database_name from dual;
> > > 
> > > ORA_DATABASE_NAME
> > >
> > --
> > --
> > > 
> > > PMEDI01.ARSENALDIGITAL.COM
> > > 
> > > 
> > > 
> > > Best regards,
> > > 
> > > David B. Wagoner
> > > Database Administrator
> > > Arsenal Digital Solutions
> > > 
> > > 
> > > 
> > > -Original Message-
> > > Sent: Wednesday, September 10, 2003 10:00 PM
> > > To: Multiple recipients of list ORACLE-L
> > > 
> > > 
> > > How about SELECT ORA_DATABASE_NAME FROM DUAL;
> > > 
> > > HTH
> > > GovindanK
> > > 
> > > > select sys_context('USERENV','DB_NAME') from
> > > ;
> > > >
> > > > At 10:49 AM 9/10/2003 -0800, you wrote:
> > > >>hi.
> > > >>
> > > >>I think there was a dbms package to get some of
> > > >>the environment variables for a session, but I
> > > can't
> > > >>remember anyhting specific. If someone know what
> > > I'm
> > > >>talking about and has any details, please Email me
> > > or
> > > >>post here
> > > >>
> > > >>thanks
> > > >>
> > > >>Gene
> > > >
> > > > Wolfgang Breitling
> > > > Oracle7, 8, 8i, 9i OCP DBA
> > > > Centrex Consulting Corporation
> > > > http://www.centrexcc.com
> > > >
> > > >
> > > >
> > > 
> > > --
> > > Please see the official ORACLE-L FAQ:
> > > http://www.orafaq.net
> > > -- 
> > > Author: GovindanK
> > >   INET: [EMAIL PROTECTED]
> > > 
> > > Fat City Network Services-- 858-538-5051
> > > http://www.fatcity.com
> > > San Diego, California-- Mailing list and web
> > > hosting services
> > >
> >
> ---

RE: how can I see which database I am logged into without - thanks!!!

2003-09-12 Thread Gene Gurevich

Hi.

Just wanted to thank all who replied to my original
question. I was only looking for one way and I got
several from different people (which is great) within
just a few hours. Thanks you all very much!!!

Gene


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Gene Gurevich
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


RE: how can I see which database I am logged into without

2003-09-11 Thread Alexander . Feinstein
Title: RE: how can I see which database I am logged into without





In 9.2, in SQL*Plus


prompt &_connect_identifier


Alex.
(Thanks to Connor McDonald)




-Original Message-
From: Jose Luis Delgado [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, September 11, 2003 2:54 PM
To: Multiple recipients of list ORACLE-L
Subject: RE: how can I see which database I am logged into without



Funny.


--- Mladen Gogala <[EMAIL PROTECTED]> wrote:
> How about:
> 
> SELECT 'RUMPELSTILSKIN' FROM DUAL;
> 
> That should be a good guess.
> 
> --
> Mladen Gogala
> Oracle DBA
> 
> 
> 
> > -Original Message-
> > From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]] On
> > Behalf Of Jose Luis Delgado
> > Sent: Thursday, September 11, 2003 4:38 PM
> > To: Multiple recipients of list ORACLE-L
> > Subject: RE: how can I see which database I am
> logged into without
> > 
> > 
> > Can you try:
> > 
> > select global_name from global_name;???
> > 
> > compare it with your
> > select ora_database_name from dual
> > 
> > Are they the same?
> > 
> > HTH
> > JL
> > 
> > --- David Wagoner <[EMAIL PROTECTED]>
> wrote:
> > > You might get some surprising results from
> SELECT ORA_DATABASE_NAME
> > > FROM DUAL; (see below).  I have a DEV database
> cloned
> > > from Prod. and it still
> > > lists the Prod. DB name with that query.  Where
> is
> > > it reading the name from?
> > > You can see that other queries produce the
> "correct"
> > > name.
> > > 
> > > 
> > > SQL> select instance_name from v$instance;
> > > 
> > > INSTANCE_NAME
> > > 
> > > dmedi01
> > > 
> > > SQL> show parameter name;
> > > 
> > > NAME TYPE   
> > > VALUE
> > >  ---
> > > --
> > > db_file_name_convert string
> > > db_name  string 
> > > dmedi01
> > > global_names boolean    
> > > FALSE
> > > instance_name    string 
> > > dmedi01
> > > lock_name_space  string
> > > log_file_name_convert    string
> > > oracle_trace_collection_name string
> > > oracle_trace_facility_name   string 
> > > oracled
> > > plsql_native_make_file_name  string
> > > service_names    string 
> > > dmedi01.arsenaldigital.com
> > > 
> > > SQL> select ora_database_name from dual;
> > > 
> > > ORA_DATABASE_NAME
> > >
> >
>
--
> > --
> > > 
> > > PMEDI01.ARSENALDIGITAL.COM
> > > 
> > > 
> > > 
> > > Best regards,
> > > 
> > > David B. Wagoner
> > > Database Administrator
> > > Arsenal Digital Solutions
> > > 
> > > 
> > > 
> > > -Original Message-
> > > Sent: Wednesday, September 10, 2003 10:00 PM
> > > To: Multiple recipients of list ORACLE-L
> > > 
> > > 
> > > How about SELECT ORA_DATABASE_NAME FROM DUAL;
> > > 
> > > HTH
> > > GovindanK
> > > 
> > > > select sys_context('USERENV','DB_NAME') from
> > > ;
> > > >
> > > > At 10:49 AM 9/10/2003 -0800, you wrote:
> > > >>hi.
> > > >>
> > > >>I think there was a dbms package to get some
> of
> > > >>the environment variables for a session, but I
> > > can't
> > > >>remember anyhting specific. If someone know
> what
> > > I'm
> > > >>talking about and has any details, please
> Email me
> > > or
> > > >>post here
> > > >>
> > > >>thanks
> > > >>
> > > >>Gene
> > > >
> > > > Wolfgang Breitling
> > > > Oracle7, 8, 8i, 9i OCP DBA
> > > > Centrex Consulting Corporation
> > > > http://www.centrexcc.com
> > > >
> > > >
> > > >
> > > 
> > > --
> > > Please see the official ORACLE-L FAQ: http://www.orafaq.net
> > > -- 
> > > Author: GovindanK
> 

RE: how can I see which database I am logged into without

2003-09-11 Thread Jose Luis Delgado
Funny.

--- Mladen Gogala <[EMAIL PROTECTED]> wrote:
> How about:
> 
> SELECT 'RUMPELSTILSKIN' FROM DUAL;
> 
> That should be a good guess.
> 
> --
> Mladen Gogala
> Oracle DBA 
> 
> 
> 
> > -Original Message-
> > From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On 
> > Behalf Of Jose Luis Delgado
> > Sent: Thursday, September 11, 2003 4:38 PM
> > To: Multiple recipients of list ORACLE-L
> > Subject: RE: how can I see which database I am
> logged into without
> > 
> > 
> > Can you try:
> > 
> > select global_name from global_name;???
> > 
> > compare it with your 
> > select ora_database_name from dual
> > 
> > Are they the same?
> > 
> > HTH
> > JL
> > 
> > --- David Wagoner <[EMAIL PROTECTED]>
> wrote:
> > > You might get some surprising results from
> SELECT ORA_DATABASE_NAME 
> > > FROM DUAL; (see below).  I have a DEV database
> cloned
> > > from Prod. and it still
> > > lists the Prod. DB name with that query.  Where
> is
> > > it reading the name from?
> > > You can see that other queries produce the
> "correct"
> > > name.
> > > 
> > > 
> > > SQL> select instance_name from v$instance;
> > > 
> > > INSTANCE_NAME
> > > 
> > > dmedi01
> > > 
> > > SQL> show parameter name;
> > > 
> > > NAME TYPE   
> > > VALUE
> > >  ---
> > > --
> > > db_file_name_convert string
> > > db_name  string 
> > > dmedi01
> > > global_names boolean
> > > FALSE
> > > instance_namestring 
> > > dmedi01
> > > lock_name_space  string
> > > log_file_name_convertstring
> > > oracle_trace_collection_name string
> > > oracle_trace_facility_name   string 
> > > oracled
> > > plsql_native_make_file_name  string
> > > service_namesstring 
> > > dmedi01.arsenaldigital.com
> > > 
> > > SQL> select ora_database_name from dual;
> > > 
> > > ORA_DATABASE_NAME
> > >
> >
>
--
> > --
> > > 
> > > PMEDI01.ARSENALDIGITAL.COM
> > > 
> > > 
> > > 
> > > Best regards,
> > > 
> > > David B. Wagoner
> > > Database Administrator
> > > Arsenal Digital Solutions
> > > 
> > > 
> > > 
> > > -Original Message-
> > > Sent: Wednesday, September 10, 2003 10:00 PM
> > > To: Multiple recipients of list ORACLE-L
> > > 
> > > 
> > > How about SELECT ORA_DATABASE_NAME FROM DUAL;
> > > 
> > > HTH
> > > GovindanK
> > > 
> > > > select sys_context('USERENV','DB_NAME') from
> > > ;
> > > >
> > > > At 10:49 AM 9/10/2003 -0800, you wrote:
> > > >>hi.
> > > >>
> > > >>I think there was a dbms package to get some
> of
> > > >>the environment variables for a session, but I
> > > can't
> > > >>remember anyhting specific. If someone know
> what
> > > I'm
> > > >>talking about and has any details, please
> Email me
> > > or
> > > >>post here
> > > >>
> > > >>thanks
> > > >>
> > > >>Gene
> > > >
> > > > Wolfgang Breitling
> > > > Oracle7, 8, 8i, 9i OCP DBA
> > > > Centrex Consulting Corporation
> > > > http://www.centrexcc.com
> > > >
> > > >
> > > >
> > > 
> > > --
> > > Please see the official ORACLE-L FAQ:
> > > http://www.orafaq.net
> > > -- 
> > > Author: GovindanK
> > >   INET: [EMAIL PROTECTED]
> > > 
> > > Fat City Network Services-- 858-538-5051
> > > http://www.fatcity.com
> > > San Diego, California-- Mailing list and
> web
> > > hosting services
> > >
> >
>
-
> > > To REMOVE yo

RE: how can I see which database I am logged into without

2003-09-11 Thread Mladen Gogala
How about:

SELECT 'RUMPELSTILSKIN' FROM DUAL;

That should be a good guess.

--
Mladen Gogala
Oracle DBA 



> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On 
> Behalf Of Jose Luis Delgado
> Sent: Thursday, September 11, 2003 4:38 PM
> To: Multiple recipients of list ORACLE-L
> Subject: RE: how can I see which database I am logged into without
> 
> 
> Can you try:
> 
> select global_name from global_name;???
> 
> compare it with your 
> select ora_database_name from dual
> 
> Are they the same?
> 
> HTH
> JL
> 
> --- David Wagoner <[EMAIL PROTECTED]> wrote:
> > You might get some surprising results from SELECT ORA_DATABASE_NAME 
> > FROM DUAL; (see below).  I have a DEV database cloned
> > from Prod. and it still
> > lists the Prod. DB name with that query.  Where is
> > it reading the name from?
> > You can see that other queries produce the "correct"
> > name.
> > 
> > 
> > SQL> select instance_name from v$instance;
> > 
> > INSTANCE_NAME
> > 
> > dmedi01
> > 
> > SQL> show parameter name;
> > 
> > NAME TYPE   
> > VALUE
> >  ---
> > --
> > db_file_name_convert string
> > db_name  string 
> > dmedi01
> > global_names boolean
> > FALSE
> > instance_namestring 
> > dmedi01
> > lock_name_space  string
> > log_file_name_convertstring
> > oracle_trace_collection_name string
> > oracle_trace_facility_name   string 
> > oracled
> > plsql_native_make_file_name  string
> > service_namesstring 
> > dmedi01.arsenaldigital.com
> > 
> > SQL> select ora_database_name from dual;
> > 
> > ORA_DATABASE_NAME
> >
> --
> --
> > 
> > PMEDI01.ARSENALDIGITAL.COM
> > 
> > 
> > 
> > Best regards,
> > 
> > David B. Wagoner
> > Database Administrator
> > Arsenal Digital Solutions
> > 
> > 
> > 
> > -Original Message-
> > Sent: Wednesday, September 10, 2003 10:00 PM
> > To: Multiple recipients of list ORACLE-L
> > 
> > 
> > How about SELECT ORA_DATABASE_NAME FROM DUAL;
> > 
> > HTH
> > GovindanK
> > 
> > > select sys_context('USERENV','DB_NAME') from
> > ;
> > >
> > > At 10:49 AM 9/10/2003 -0800, you wrote:
> > >>hi.
> > >>
> > >>I think there was a dbms package to get some of
> > >>the environment variables for a session, but I
> > can't
> > >>remember anyhting specific. If someone know what
> > I'm
> > >>talking about and has any details, please Email me
> > or
> > >>post here
> > >>
> > >>thanks
> > >>
> > >>Gene
> > >
> > > Wolfgang Breitling
> > > Oracle7, 8, 8i, 9i OCP DBA
> > > Centrex Consulting Corporation
> > > http://www.centrexcc.com
> > >
> > >
> > >
> > 
> > --
> > Please see the official ORACLE-L FAQ:
> > http://www.orafaq.net
> > -- 
> > Author: GovindanK
> >   INET: [EMAIL PROTECTED]
> > 
> > Fat City Network Services-- 858-538-5051
> > http://www.fatcity.com
> > San Diego, California-- Mailing list and web
> > hosting services
> >
> -
> > To REMOVE yourself from this mailing list, send an
> > E-Mail message
> > to: [EMAIL PROTECTED] (note EXACT spelling of
> > 'ListGuru') and in
> > the message BODY, include a line containing: UNSUB
> > ORACLE-L
> > (or the name of mailing list you want to be removed
> > from).  You may
> > also send the HELP command for other information
> > (like subscribing).
> > 
> 
> 
> __
> Do you Yahoo!?
> Yahoo! SiteBuilder - Free, easy-to-use web site design 
> software http://sitebuilder.yahoo.com
> -- 
> Please see the official ORACLE-L FAQ: http://www.orafaq.net
> -- 
> Author: Jose Luis Delgado
>   INET: [EMAIL PROTECTED]
> 
> Fat City Network Services-- 858-538-5051 http://www.fatcity

RE: how can I see which database I am logged into without

2003-09-11 Thread Jose Luis Delgado
Can you try:

select global_name from global_name;???

compare it with your 
select ora_database_name from dual

Are they the same?

HTH
JL

--- David Wagoner <[EMAIL PROTECTED]> wrote:
> You might get some surprising results from SELECT
> ORA_DATABASE_NAME FROM
> DUAL; (see below).  I have a DEV database cloned
> from Prod. and it still
> lists the Prod. DB name with that query.  Where is
> it reading the name from?
> You can see that other queries produce the "correct"
> name.
> 
> 
> SQL> select instance_name from v$instance;
> 
> INSTANCE_NAME
> 
> dmedi01
> 
> SQL> show parameter name;
> 
> NAME TYPE   
> VALUE
>  ---
> --
> db_file_name_convert string
> db_name  string 
> dmedi01
> global_names boolean
> FALSE
> instance_namestring 
> dmedi01
> lock_name_space  string
> log_file_name_convertstring
> oracle_trace_collection_name string
> oracle_trace_facility_name   string 
> oracled
> plsql_native_make_file_name  string
> service_namesstring 
> dmedi01.arsenaldigital.com
> 
> SQL> select ora_database_name from dual;
> 
> ORA_DATABASE_NAME
>

> 
> PMEDI01.ARSENALDIGITAL.COM
> 
> 
> 
> Best regards,
> 
> David B. Wagoner
> Database Administrator
> Arsenal Digital Solutions
> 
> 
> 
> -Original Message-
> Sent: Wednesday, September 10, 2003 10:00 PM
> To: Multiple recipients of list ORACLE-L
> 
> 
> How about SELECT ORA_DATABASE_NAME FROM DUAL;
> 
> HTH
> GovindanK
> 
> > select sys_context('USERENV','DB_NAME') from
> ;
> >
> > At 10:49 AM 9/10/2003 -0800, you wrote:
> >>hi.
> >>
> >>I think there was a dbms package to get some of
> >>the environment variables for a session, but I
> can't
> >>remember anyhting specific. If someone know what
> I'm
> >>talking about and has any details, please Email me
> or
> >>post here
> >>
> >>thanks
> >>
> >>Gene
> >
> > Wolfgang Breitling
> > Oracle7, 8, 8i, 9i OCP DBA
> > Centrex Consulting Corporation
> > http://www.centrexcc.com
> >
> >
> >
> 
> -- 
> Please see the official ORACLE-L FAQ:
> http://www.orafaq.net
> -- 
> Author: GovindanK
>   INET: [EMAIL PROTECTED]
> 
> Fat City Network Services-- 858-538-5051
> http://www.fatcity.com
> San Diego, California-- Mailing list and web
> hosting services
>
-
> To REMOVE yourself from this mailing list, send an
> E-Mail message
> to: [EMAIL PROTECTED] (note EXACT spelling of
> 'ListGuru') and in
> the message BODY, include a line containing: UNSUB
> ORACLE-L
> (or the name of mailing list you want to be removed
> from).  You may
> also send the HELP command for other information
> (like subscribing).
> 


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Jose Luis Delgado
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


RE: how can I see which database I am logged into without

2003-09-11 Thread Spears, Brian
how about select from v$database;

bs

-Original Message-
Sent: Thursday, September 11, 2003 9:40 AM
To: Multiple recipients of list ORACLE-L


Hi,
this statement returns the GLOBAL_NAME value rather than the database name. 
Admittedly the 2 should usually be the same but often (following a database
clone for instance) it is not correctly set.

Regards,
Mike Hately

- Original Message - 
To: "Multiple recipients of list ORACLE-L" <[EMAIL PROTECTED]>
Sent: Thursday, September 11, 2003 4:59 AM


> How about SELECT ORA_DATABASE_NAME FROM DUAL;
> 
> HTH
> GovindanK



> 
> > select sys_context('USERENV','DB_NAME') from ;
> >
> > At 10:49 AM 9/10/2003 -0800, you wrote:
> >>hi.
> >>
> >>I think there was a dbms package to get some of
> >>the environment variables for a session, but I can't
> >>remember anyhting specific. If someone know what I'm
> >>talking about and has any details, please Email me or
> >>post here
> >>
> >>thanks
> >>
> >>Gene
> >
> > Wolfgang Breitling
> > Oracle7, 8, 8i, 9i OCP DBA
> > Centrex Consulting Corporation
> > http://www.centrexcc.com




E mail Disclaimer

You agree that you have read and understood this disclaimer and you agree to
be bound by its terms.

The information contained in this e-mail and any files transmitted with it
(if any) are confidential and intended for the addressee only.  If you have
received this  e-mail in error please notify the originator.

This e-mail and any attachments have been scanned for certain viruses prior
to sending but CE Electric UK Funding Company nor any of its associated
companies from whom this e-mail originates shall be liable for any losses as
a result of any viruses being passed on.

No warranty of any kind is given in respect of any information contained in
this   e-mail and you should be aware that that it might be incomplete, out
of date or incorrect. It is therefore essential that you verify all such
information with us before placing any reliance upon it.

CE Electric UK Funding Company
Lloyds Court
78 Grey Street
Newcastle upon Tyne
NE1 6AF
Registered in England and Wales: Number 3476201




-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Hately, Mike (LogicaCMG)
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Spears, Brian
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


RE: how can I see which database I am logged into without

2003-09-11 Thread Stephane Paquette
Title: RE: how can I see which database I am logged into without



When 
the database was cloned from prod, did the global name changed (alter databeas 
db rename global_name  to ...)
Maybe 
ora_database_name takes it from global_name.
 
 



Stephane Paquette
Administrateur 
de bases de donnees
Database 
Administrator
Standard 
Life
www.standardlife.ca
Tel. 
(514) 499-7999 7470 and (514) 925-7187
[EMAIL PROTECTED]

  -Original Message-From: [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED]On Behalf Of David 
  WagonerSent: Thursday, September 11, 2003 3:34 PMTo: 
  Multiple recipients of list ORACLE-LSubject: RE: how can I see 
  which database I am logged into without
  You might get some surprising results from SELECT 
  ORA_DATABASE_NAME FROM DUAL; (see below).  I have a DEV database cloned 
  from Prod. and it still lists the Prod. DB name with that query.  Where 
  is it reading the name from?  You can see that other queries produce the 
  "correct" name.
  SQL> select instance_name from v$instance; 
  INSTANCE_NAME  
  dmedi01 
  SQL> show parameter name; 
  NAME 
  TYPE    VALUE  --- 
  -- db_file_name_convert 
  string db_name  
  string  dmedi01 global_names 
  boolean FALSE instance_name    
  string  dmedi01 lock_name_space  
  string log_file_name_convert    
  string oracle_trace_collection_name 
  string oracle_trace_facility_name   
  string  oracled plsql_native_make_file_name  
  string service_names    
  string  dmedi01.arsenaldigital.com 
  SQL> select ora_database_name from dual; 
  ORA_DATABASE_NAME  
  PMEDI01.ARSENALDIGITAL.COM 
  Best regards, 
  David B. Wagoner Database 
  Administrator Arsenal Digital Solutions 
  
  -Original Message- From: 
  GovindanK [mailto:[EMAIL PROTECTED]] 
  Sent: Wednesday, September 10, 2003 10:00 PM To: Multiple recipients of list ORACLE-L Subject: Re: how can I see which database I am logged into 
  without 
  How about SELECT ORA_DATABASE_NAME FROM DUAL; 
  HTH GovindanK 
  > select sys_context('USERENV','DB_NAME') from 
  ; > > At 
  10:49 AM 9/10/2003 -0800, you wrote: >>hi. >> >>I think there was a dbms package to get some of 
  >>the environment variables for a session, but I 
  can't >>remember anyhting specific. If someone 
  know what I'm >>talking about and has any 
  details, please Email me or >>post here 
  >> >>thanks 
  >> >>Gene 
  > > Wolfgang Breitling 
  > Oracle7, 8, 8i, 9i OCP DBA > 
  Centrex Consulting Corporation > http://www.centrexcc.com > 
  > > 
  -- Please see the official ORACLE-L 
  FAQ: http://www.orafaq.net -- 
  Author: GovindanK   INET: 
  [EMAIL PROTECTED] 
  Fat City Network Services    -- 858-538-5051 http://www.fatcity.com 
  San Diego, 
  California    -- Mailing list and web 
  hosting services - 
  To REMOVE yourself from this mailing list, send an E-Mail 
  message to: [EMAIL PROTECTED] (note EXACT spelling 
  of 'ListGuru') and in the message BODY, include a line 
  containing: UNSUB ORACLE-L (or the name of mailing 
  list you want to be removed from).  You may also 
  send the HELP command for other information (like subscribing). 



Re: how can I see which database I am logged into without

2003-09-11 Thread Tanel Poder
It's sys.props$ if it reflects global dbname.

Tanel.

- Original Message - 
To: "Multiple recipients of list ORACLE-L" <[EMAIL PROTECTED]>
Sent: Thursday, September 11, 2003 11:37 PM


>
> Just a guess..most possibly it is fetching from v$databaseAfter
cloning
> from production, if you don't change db_name explicitly for dev database ,
> it will show production databse name in v$database
>
> Regards
> Rafiq
>
>
>
>
>
>
>
> Reply-To: [EMAIL PROTECTED]
> To: Multiple recipients of list ORACLE-L <[EMAIL PROTECTED]>
> Date: Thu, 11 Sep 2003 11:34:24 -0800
>
> You might get some surprising results from SELECT ORA_DATABASE_NAME FROM
> DUAL; (see below).  I have a DEV database cloned from Prod. and it still
> lists the Prod. DB name with that query.  Where is it reading the name
from?
> You can see that other queries produce the "correct" name.
>
>
> SQL> select instance_name from v$instance;
>
> INSTANCE_NAME
> 
> dmedi01
>
> SQL> show parameter name;
>
> NAME TYPEVALUE
>  ---
> --
> db_file_name_convert string
> db_name  string  dmedi01
> global_names boolean FALSE
> instance_namestring  dmedi01
> lock_name_space  string
> log_file_name_convertstring
> oracle_trace_collection_name string
> oracle_trace_facility_name   string  oracled
> plsql_native_make_file_name  string
> service_namesstring
dmedi01.arsenaldigital.com
>
> SQL> select ora_database_name from dual;
>
> ORA_DATABASE_NAME
> --
--
> 
> PMEDI01.ARSENALDIGITAL.COM
>
>
>
> Best regards,
>
> David B. Wagoner
> Database Administrator
> Arsenal Digital Solutions
>
>
>
> -Original Message-
> Sent: Wednesday, September 10, 2003 10:00 PM
> To: Multiple recipients of list ORACLE-L
>
>
> How about SELECT ORA_DATABASE_NAME FROM DUAL;
>
> HTH
> GovindanK
>
>  > select sys_context('USERENV','DB_NAME') from ;
>  >
>  > At 10:49 AM 9/10/2003 -0800, you wrote:
>  >>hi.
>  >>
>  >>I think there was a dbms package to get some of
>  >>the environment variables for a session, but I can't
>  >>remember anyhting specific. If someone know what I'm
>  >>talking about and has any details, please Email me or
>  >>post here
>  >>
>  >>thanks
>  >>
>  >>Gene
>  >
>  > Wolfgang Breitling
>  > Oracle7, 8, 8i, 9i OCP DBA
>  > Centrex Consulting Corporation
>  > http://www.centrexcc.com
>  >
>  >
>  >
>
> --
> Please see the official ORACLE-L FAQ: http://www.orafaq.net
> --
> Author: GovindanK
>INET: [EMAIL PROTECTED]
>
> Fat City Network Services-- 858-538-5051 http://www.fatcity.com
> San Diego, California-- Mailing list and web hosting services
> -
> To REMOVE yourself from this mailing list, send an E-Mail message
> to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
> the message BODY, include a line containing: UNSUB ORACLE-L
> (or the name of mailing list you want to be removed from).  You may
> also send the HELP command for other information (like subscribing).
>
> _
> Get a FREE computer virus scan online from McAfee.
> http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963
>
> -- 
> Please see the official ORACLE-L FAQ: http://www.orafaq.net
> -- 
> Author: M Rafiq
>   INET: [EMAIL PROTECTED]
>
> Fat City Network Services-- 858-538-5051 http://www.fatcity.com
> San Diego, California-- Mailing list and web hosting services
> -
> To REMOVE yourself from this mailing list, send an E-Mail message
> to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
> the message BODY, include a line containing: UNSUB ORACLE-L
> (or the name of mailing list you want to be removed from).  You may
> also send the HELP command for other information (like subscribing).
>


-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Tanel Poder
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


RE: how can I see which database I am logged into without

2003-09-11 Thread raju pa
Maybe from service_name in init ora file. David Wagoner <[EMAIL PROTECTED]> wrote:


You might get some surprising results from SELECT ORA_DATABASE_NAME FROM DUAL; (see below).  I have a DEV database cloned from Prod. and it still lists the Prod. DB name with that query.  Where is it reading the name from?  You can see that other queries produce the "correct" name.
SQL> select instance_name from v$instance; 
INSTANCE_NAME  dmedi01 
SQL> show parameter name; 
NAME TYPE    VALUE  --- -- db_file_name_convert string db_name  string  dmedi01 global_names boolean FALSE
 instance_name    string  dmedi01 lock_name_space  string log_file_name_convert    string oracle_trace_collection_name string oracle_trace_facility_name   string  oracled plsql_native_make_file_name  string service_names    string  dmedi01.arsenaldigital.com 
SQL> select ora_database_name from dual; 
ORA_DATABASE_NAME  PMEDI01.ARSENALDIGITAL.COM 
Best regards, 
David B. Wagoner Database Administrator Arsenal Digital Solutions 
-Original Message- From: GovindanK [mailto:[EMAIL PROTECTED]] Sent: Wednesday, September 10, 2003 10:00 PM To: Multiple recipients of list ORACLE-L Subject: Re: how can I see which database I am logged into without 
How about SELECT ORA_DATABASE_NAME FROM DUAL; 
HTH GovindanK 
> select sys_context('USERENV','DB_NAME') from ; > > At 10:49 AM 9/10/2003 -0800, you wrote: >>hi. >> >>I think there was a dbms package to get some of >>the environment variables for a session, but I can't >>remember anyhting specific. If someone know what I'm >>talking about and has any details, please Email me or >>post here >> >>thanks >> >>Gene > > Wolfgang Breitling > Oracle7, 8, 8i, 9i OCP DBA > Centrex Consulting Corporation &!
gt; http://www.centrexcc.com > > > 
-- Please see the official ORACLE-L FAQ: http://www.orafaq.net -- Author: GovindanK   INET: [EMAIL PROTECTED] 
Fat City Network Services    -- 858-538-5051 http://www.fatcity.com San Diego, California    -- Mailing list and web hosting services - To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from).  You may also send the HELP command for other information (like subscribing). 
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software

RE: how can I see which database I am logged into without

2003-09-11 Thread M Rafiq
Just a guess..most possibly it is fetching from v$databaseAfter cloning 
from production, if you don't change db_name explicitly for dev database , 
it will show production databse name in v$database

Regards
Rafiq






Reply-To: [EMAIL PROTECTED]
To: Multiple recipients of list ORACLE-L <[EMAIL PROTECTED]>
Date: Thu, 11 Sep 2003 11:34:24 -0800
You might get some surprising results from SELECT ORA_DATABASE_NAME FROM
DUAL; (see below).  I have a DEV database cloned from Prod. and it still
lists the Prod. DB name with that query.  Where is it reading the name from?
You can see that other queries produce the "correct" name.
SQL> select instance_name from v$instance;

INSTANCE_NAME

dmedi01
SQL> show parameter name;

NAME TYPEVALUE
 ---
--
db_file_name_convert string
db_name  string  dmedi01
global_names boolean FALSE
instance_namestring  dmedi01
lock_name_space  string
log_file_name_convertstring
oracle_trace_collection_name string
oracle_trace_facility_name   string  oracled
plsql_native_make_file_name  string
service_namesstring  dmedi01.arsenaldigital.com
SQL> select ora_database_name from dual;

ORA_DATABASE_NAME


PMEDI01.ARSENALDIGITAL.COM


Best regards,

David B. Wagoner
Database Administrator
Arsenal Digital Solutions


-Original Message-
Sent: Wednesday, September 10, 2003 10:00 PM
To: Multiple recipients of list ORACLE-L
How about SELECT ORA_DATABASE_NAME FROM DUAL;

HTH
GovindanK
> select sys_context('USERENV','DB_NAME') from ;
>
> At 10:49 AM 9/10/2003 -0800, you wrote:
>>hi.
>>
>>I think there was a dbms package to get some of
>>the environment variables for a session, but I can't
>>remember anyhting specific. If someone know what I'm
>>talking about and has any details, please Email me or
>>post here
>>
>>thanks
>>
>>Gene
>
> Wolfgang Breitling
> Oracle7, 8, 8i, 9i OCP DBA
> Centrex Consulting Corporation
> http://www.centrexcc.com
>
>
>
--
Please see the official ORACLE-L FAQ: http://www.orafaq.net
--
Author: GovindanK
  INET: [EMAIL PROTECTED]
Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
_
Get a FREE computer virus scan online from McAfee. 
http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963

--
Please see the official ORACLE-L FAQ: http://www.orafaq.net
--
Author: M Rafiq
 INET: [EMAIL PROTECTED]
Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


RE: how can I see which database I am logged into without

2003-09-11 Thread Govindan K
Good point. Then run the following query:

select name from v$database;

HTH
GovindanK

On Thu, 11 Sep 2003 11:44 , Wolfgang Breitling <[EMAIL PROTECTED]> sent:

>What is your point? Mike Hately's statement is still correct. It returns 
>the global_name which should be, but not necessarily IS, the same as 
>db_name since it can be set to any arbitrary value. Of course, if you are 
>using replication you better set it to the correct value or it will not work:
>
>stats.scott > alter database rename global_name to something.world;
>
>Database altered.
>
>stats.scott> select ora_database_name, sys_context('USERENV','DB_NAME') 
>db_name from dual;
>
>ORA_DATABASE_NAME  DB_NAME
>-- 
>SOMETHING.WORLDstats
>
>1 row selected.
>
>
>At 10:59 AM 9/11/2003 -0800, you wrote:
>>/u005/oracle/product/rdbms/admin> ls -l dbmstrig.sql
>>-rw-r--r--   1 oracle   dba 8657 Apr 28  2002 dbmstrig.sql
>>
>>/u005/oracle/product/9.2.0/rdbms/admin> sed -n '76,85p' dbmstrig.sql
>>Rem returns the current database name
>>create or replace function database_name return varchar2 is
>>begin
>>return dbms_standard.database_name;
>>end;
>>/
>>grant execute on database_name to public
>>/
>>create or replace public synonym ora_database_name for database_name
>>/
>>
>>/u005/oracle/product/9.2.0/rdbms/admin>
>>
>>HTH
>>GovindanK
>>
>>On Thu, 11 Sep 2003 05:39 , Hately, Mike (LogicaCMG) 
>>[EMAIL PROTECTED]> sent:
>>
>> >Hi,
>> >this statement returns the GLOBAL_NAME value rather than the database name.
>> >Admittedly the 2 should usually be the same but often (following a database
>> >clone for instance) it is not correctly set.
>> >
>> >Regards,
>> >Mike Hately
>
>Wolfgang Breitling
>Oracle7, 8, 8i, 9i OCP DBA
>Centrex Consulting Corporation
>http://www.centrexcc.com


 Message sent via Zuvio Mail
Get your own FREE email account with SPAM and Antivirus protection!
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Govindan K
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


RE: how can I see which database I am logged into without

2003-09-11 Thread David Wagoner
Title: RE: how can I see which database I am logged into without





My point was that you can see different names by using different queries.  But, you and Mike brought up a good point- I need to use the "alter database rename global_name to XXX" after cloning databases to avoid any such confusion.  Thanks for that tip.


Best regards,


David B. Wagoner
Database Administrator
Arsenal Digital Solutions



-Original Message-
From: Wolfgang Breitling [mailto:[EMAIL PROTECTED]]
Sent: Thursday, September 11, 2003 3:44 PM
To: Multiple recipients of list ORACLE-L
Subject: RE: how can I see which database I am logged into without



What is your point? Mike Hately's statement is still correct. It returns 
the global_name which should be, but not necessarily IS, the same as 
db_name since it can be set to any arbitrary value. Of course, if you are 
using replication you better set it to the correct value or it will not work:


stats.scott > alter database rename global_name to something.world;


Database altered.


stats.scott> select ora_database_name, sys_context('USERENV','DB_NAME') 
db_name from dual;


ORA_DATABASE_NAME  DB_NAME
-- 
SOMETHING.WORLD    stats


1 row selected.



At 10:59 AM 9/11/2003 -0800, you wrote:
>/u005/oracle/product/rdbms/admin> ls -l dbmstrig.sql
>-rw-r--r--   1 oracle   dba 8657 Apr 28  2002 dbmstrig.sql
>
>/u005/oracle/product/9.2.0/rdbms/admin> sed -n '76,85p' dbmstrig.sql
>Rem returns the current database name
>create or replace function database_name return varchar2 is
>begin
>return dbms_standard.database_name;
>end;
>/
>grant execute on database_name to public
>/
>create or replace public synonym ora_database_name for database_name
>/
>
>/u005/oracle/product/9.2.0/rdbms/admin>
>
>HTH
>GovindanK
>
>On Thu, 11 Sep 2003 05:39 , Hately, Mike (LogicaCMG) 
><[EMAIL PROTECTED]> sent:
>
> >Hi,
> >this statement returns the GLOBAL_NAME value rather than the database name.
> >Admittedly the 2 should usually be the same but often (following a database
> >clone for instance) it is not correctly set.
> >
> >Regards,
> >Mike Hately


Wolfgang Breitling
Oracle7, 8, 8i, 9i OCP DBA
Centrex Consulting Corporation
http://www.centrexcc.com



-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Wolfgang Breitling
  INET: [EMAIL PROTECTED]


Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California    -- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).





RE: how can I see which database I am logged into without

2003-09-11 Thread Wolfgang Breitling
What is your point? Mike Hately's statement is still correct. It returns 
the global_name which should be, but not necessarily IS, the same as 
db_name since it can be set to any arbitrary value. Of course, if you are 
using replication you better set it to the correct value or it will not work:

stats.scott > alter database rename global_name to something.world;

Database altered.

stats.scott> select ora_database_name, sys_context('USERENV','DB_NAME') 
db_name from dual;

ORA_DATABASE_NAME  DB_NAME
-- 
SOMETHING.WORLDstats
1 row selected.

At 10:59 AM 9/11/2003 -0800, you wrote:
/u005/oracle/product/rdbms/admin> ls -l dbmstrig.sql
-rw-r--r--   1 oracle   dba 8657 Apr 28  2002 dbmstrig.sql
/u005/oracle/product/9.2.0/rdbms/admin> sed -n '76,85p' dbmstrig.sql
Rem returns the current database name
create or replace function database_name return varchar2 is
begin
return dbms_standard.database_name;
end;
/
grant execute on database_name to public
/
create or replace public synonym ora_database_name for database_name
/
/u005/oracle/product/9.2.0/rdbms/admin>

HTH
GovindanK
On Thu, 11 Sep 2003 05:39 , Hately, Mike (LogicaCMG) 
<[EMAIL PROTECTED]> sent:

>Hi,
>this statement returns the GLOBAL_NAME value rather than the database name.
>Admittedly the 2 should usually be the same but often (following a database
>clone for instance) it is not correctly set.
>
>Regards,
>Mike Hately
Wolfgang Breitling
Oracle7, 8, 8i, 9i OCP DBA
Centrex Consulting Corporation
http://www.centrexcc.com
--
Please see the official ORACLE-L FAQ: http://www.orafaq.net
--
Author: Wolfgang Breitling
 INET: [EMAIL PROTECTED]
Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


RE: how can I see which database I am logged into without

2003-09-11 Thread David Wagoner
Title: RE: how can I see which database I am logged into without





You might get some surprising results from SELECT ORA_DATABASE_NAME FROM DUAL; (see below).  I have a DEV database cloned from Prod. and it still lists the Prod. DB name with that query.  Where is it reading the name from?  You can see that other queries produce the "correct" name.


SQL> select instance_name from v$instance;


INSTANCE_NAME

dmedi01


SQL> show parameter name;


NAME TYPE    VALUE
 --- --
db_file_name_convert string
db_name  string  dmedi01
global_names boolean FALSE
instance_name    string  dmedi01
lock_name_space  string
log_file_name_convert    string
oracle_trace_collection_name string
oracle_trace_facility_name   string  oracled
plsql_native_make_file_name  string
service_names    string  dmedi01.arsenaldigital.com


SQL> select ora_database_name from dual;


ORA_DATABASE_NAME

PMEDI01.ARSENALDIGITAL.COM




Best regards,


David B. Wagoner
Database Administrator
Arsenal Digital Solutions




-Original Message-
From: GovindanK [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, September 10, 2003 10:00 PM
To: Multiple recipients of list ORACLE-L
Subject: Re: how can I see which database I am logged into without



How about SELECT ORA_DATABASE_NAME FROM DUAL;


HTH
GovindanK


> select sys_context('USERENV','DB_NAME') from ;
>
> At 10:49 AM 9/10/2003 -0800, you wrote:
>>hi.
>>
>>I think there was a dbms package to get some of
>>the environment variables for a session, but I can't
>>remember anyhting specific. If someone know what I'm
>>talking about and has any details, please Email me or
>>post here
>>
>>thanks
>>
>>Gene
>
> Wolfgang Breitling
> Oracle7, 8, 8i, 9i OCP DBA
> Centrex Consulting Corporation
> http://www.centrexcc.com
>
>
>


-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: GovindanK
  INET: [EMAIL PROTECTED]


Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California    -- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).





RE: how can I see which database I am logged into without

2003-09-11 Thread Govindan K
/u005/oracle/product/rdbms/admin> ls -l dbmstrig.sql
-rw-r--r--   1 oracle   dba 8657 Apr 28  2002 dbmstrig.sql

/u005/oracle/product/9.2.0/rdbms/admin> sed -n '76,85p' dbmstrig.sql
Rem returns the current database name
create or replace function database_name return varchar2 is
begin
return dbms_standard.database_name;
end;
/
grant execute on database_name to public
/
create or replace public synonym ora_database_name for database_name
/

/u005/oracle/product/9.2.0/rdbms/admin> 

HTH
GovindanK

On Thu, 11 Sep 2003 05:39 , Hately, Mike (LogicaCMG) <[EMAIL PROTECTED]> sent:

>Hi,
>this statement returns the GLOBAL_NAME value rather than the database name. 
>Admittedly the 2 should usually be the same but often (following a database
>clone for instance) it is not correctly set.
>
>Regards,
>Mike Hately
>
>- Original Message - 
>To: "Multiple recipients of list ORACLE-L" [EMAIL PROTECTED]>
>Sent: Thursday, September 11, 2003 4:59 AM
>
>
>> How about SELECT ORA_DATABASE_NAME FROM DUAL;
>> 
>> HTH
>> GovindanK
>
>
>
>> 
>> > select sys_context('USERENV','DB_NAME') from ;
>> >
>> > At 10:49 AM 9/10/2003 -0800, you wrote:
>> >>hi.
>> >>
>> >>I think there was a dbms package to get some of
>> >>the environment variables for a session, but I can't
>> >>remember anyhting specific. If someone know what I'm
>> >>talking about and has any details, please Email me or
>> >>post here
>> >>
>> >>thanks
>> >>
>> >>Gene
>> >
>> > Wolfgang Breitling
>> > Oracle7, 8, 8i, 9i OCP DBA
>> > Centrex Consulting Corporation
>> > http://www.centrexcc.com
>
>
>
>E mail Disclaimer
>
>You agree that you have read and understood this disclaimer and you agree to be bound 
>by its terms.
>
>The information contained in this e-mail and any files transmitted with it (if any) 
>are confidential and intended for the addressee only.  If you 
have received this  e-mail in error please notify the originator.
>
>This e-mail and any attachments have been scanned for certain viruses prior to 
>sending but CE Electric UK Funding Company nor any of its 
associated companies from whom this e-mail originates shall be liable for any losses 
as a result of any viruses being passed on.
>
>No warranty of any kind is given in respect of any information contained in this   
>e-mail and you should be aware that that it might be 
incomplete, out of date or incorrect. It is therefore essential that you verify all 
such information with us before placing any reliance upon it.
>
>CE Electric UK Funding Company
>Lloyds Court
>78 Grey Street
>Newcastle upon Tyne
>NE1 6AF
>Registered in England and Wales: Number 3476201
>
>
>
>-- 
>Please see the official ORACLE-L FAQ: http://www.orafaq.net
>-- 
>Author: Hately, Mike (LogicaCMG)
>  INET: [EMAIL PROTECTED]
>
>Fat City Network Services-- 858-538-5051 http://www.fatcity.com
>San Diego, California-- Mailing list and web hosting services
>-
>To REMOVE yourself from this mailing list, send an E-Mail message
>to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
>the message BODY, include a line containing: UNSUB ORACLE-L
>(or the name of mailing list you want to be removed from).  You may
>also send the HELP command for other information (like subscribing).



 Message sent via Zuvio Mail
Get your own FREE email account with SPAM and Antivirus protection!
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Govindan K
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


RE: how can I see which database I am logged into without

2003-09-11 Thread Boivin, Patrice J
I wonder if there is a list somewhere of all the nice things DUAL can say.

: )

Patrice.

-Original Message-
Sent: Thursday, September 11, 2003 8:05 AM
To: Multiple recipients of list ORACLE-L


Thanks about this tip, I didn't know about this one :)

Tanel.

- Original Message - 
To: "Multiple recipients of list ORACLE-L" <[EMAIL PROTECTED]>
Sent: Thursday, September 11, 2003 4:59 AM


> How about SELECT ORA_DATABASE_NAME FROM DUAL;
> 
> HTH
> GovindanK
> 
> > select sys_context('USERENV','DB_NAME') from ;
> >
> > At 10:49 AM 9/10/2003 -0800, you wrote:
> >>hi.
> >>
> >>I think there was a dbms package to get some of
> >>the environment variables for a session, but I can't
> >>remember anyhting specific. If someone know what I'm
> >>talking about and has any details, please Email me or
> >>post here
> >>
> >>thanks
> >>
> >>Gene
> >
> > Wolfgang Breitling
> > Oracle7, 8, 8i, 9i OCP DBA
> > Centrex Consulting Corporation
> > http://www.centrexcc.com
> >
> >
> >
> 
> -- 
> Please see the official ORACLE-L FAQ: http://www.orafaq.net
> -- 
> Author: GovindanK
>   INET: [EMAIL PROTECTED]
> 
> Fat City Network Services-- 858-538-5051 http://www.fatcity.com
> San Diego, California-- Mailing list and web hosting services
> -
> To REMOVE yourself from this mailing list, send an E-Mail message
> to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
> the message BODY, include a line containing: UNSUB ORACLE-L
> (or the name of mailing list you want to be removed from).  You may
> also send the HELP command for other information (like subscribing).
> 

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Tanel Poder
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Boivin, Patrice J
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


RE: how can I see which database I am logged into without

2003-09-11 Thread Hately, Mike (LogicaCMG)
Hi,
this statement returns the GLOBAL_NAME value rather than the database name. 
Admittedly the 2 should usually be the same but often (following a database
clone for instance) it is not correctly set.

Regards,
Mike Hately

- Original Message - 
To: "Multiple recipients of list ORACLE-L" <[EMAIL PROTECTED]>
Sent: Thursday, September 11, 2003 4:59 AM


> How about SELECT ORA_DATABASE_NAME FROM DUAL;
> 
> HTH
> GovindanK



> 
> > select sys_context('USERENV','DB_NAME') from ;
> >
> > At 10:49 AM 9/10/2003 -0800, you wrote:
> >>hi.
> >>
> >>I think there was a dbms package to get some of
> >>the environment variables for a session, but I can't
> >>remember anyhting specific. If someone know what I'm
> >>talking about and has any details, please Email me or
> >>post here
> >>
> >>thanks
> >>
> >>Gene
> >
> > Wolfgang Breitling
> > Oracle7, 8, 8i, 9i OCP DBA
> > Centrex Consulting Corporation
> > http://www.centrexcc.com



E mail Disclaimer

You agree that you have read and understood this disclaimer and you agree to be bound 
by its terms.

The information contained in this e-mail and any files transmitted with it (if any) 
are confidential and intended for the addressee only.  If you have received this  
e-mail in error please notify the originator.

This e-mail and any attachments have been scanned for certain viruses prior to sending 
but CE Electric UK Funding Company nor any of its associated companies from whom this 
e-mail originates shall be liable for any losses as a result of any viruses being 
passed on.

No warranty of any kind is given in respect of any information contained in this   
e-mail and you should be aware that that it might be incomplete, out of date or 
incorrect. It is therefore essential that you verify all such information with us 
before placing any reliance upon it.

CE Electric UK Funding Company
Lloyds Court
78 Grey Street
Newcastle upon Tyne
NE1 6AF
Registered in England and Wales: Number 3476201



-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Hately, Mike (LogicaCMG)
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


Re: how can I see which database I am logged into without

2003-09-11 Thread Tanel Poder
Thanks about this tip, I didn't know about this one :)

Tanel.

- Original Message - 
To: "Multiple recipients of list ORACLE-L" <[EMAIL PROTECTED]>
Sent: Thursday, September 11, 2003 4:59 AM


> How about SELECT ORA_DATABASE_NAME FROM DUAL;
> 
> HTH
> GovindanK
> 
> > select sys_context('USERENV','DB_NAME') from ;
> >
> > At 10:49 AM 9/10/2003 -0800, you wrote:
> >>hi.
> >>
> >>I think there was a dbms package to get some of
> >>the environment variables for a session, but I can't
> >>remember anyhting specific. If someone know what I'm
> >>talking about and has any details, please Email me or
> >>post here
> >>
> >>thanks
> >>
> >>Gene
> >
> > Wolfgang Breitling
> > Oracle7, 8, 8i, 9i OCP DBA
> > Centrex Consulting Corporation
> > http://www.centrexcc.com
> >
> >
> >
> 
> -- 
> Please see the official ORACLE-L FAQ: http://www.orafaq.net
> -- 
> Author: GovindanK
>   INET: [EMAIL PROTECTED]
> 
> Fat City Network Services-- 858-538-5051 http://www.fatcity.com
> San Diego, California-- Mailing list and web hosting services
> -
> To REMOVE yourself from this mailing list, send an E-Mail message
> to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
> the message BODY, include a line containing: UNSUB ORACLE-L
> (or the name of mailing list you want to be removed from).  You may
> also send the HELP command for other information (like subscribing).
> 

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Tanel Poder
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


RE: Re: how can I see which database I am logged into without

2003-09-11 Thread Stephane Faroult
Didn't know this one ! Diem non perdidi.
But it seems to be the same as select global_name from global_name (on the database on 
which I have tried, both are suffixed with a .WORLD); for what I remember from my 
numerous databases cloning, the global name is something which is distinct from the 
db_name parameter - you can have two different names and you must explicitly set the 
two to be the same thing (forgetting about the domain name).
 SYS_CONTEXT('USERENV', 'DB_NAME') doesn't show any .WORLD in it and shows the same as 
select name from v$database and select value from v$parameter where name = 'db_name'.
I have always found all this extremely confusing, indeed. A database name and an 
instance name have always been enough for me - and I have always set the two to be the 
same thing as long as there was no OPS or RAC involved. I don't see the point in 
having so many names that 99.9% of people want to be the same thing.

>- --- Original Message --- -
>From: "GovindanK" <[EMAIL PROTECTED]>
>To: Multiple recipients of list ORACLE-L
><[EMAIL PROTECTED]>
>Sent: Wed, 10 Sep 2003 17:59:35
>
>How about SELECT ORA_DATABASE_NAME FROM DUAL;
>
>HTH
>GovindanK
>
>> select sys_context('USERENV','DB_NAME') from
>;
>>
>> At 10:49 AM 9/10/2003 -0800, you wrote:
>>>hi.
>>>
>>>I think there was a dbms package to get some of
>>>the environment variables for a session, but I
>can't
>>>remember anyhting specific. If someone know what
>I'm
>>>talking about and has any details, please Email
>me or
>>>post here
>>>
>>>thanks
>>>
>>>Gene
>>
>> Wolfgang Breitling
>> Oracle7, 8, 8i, 9i OCP DBA
>> Centrex Consulting Corporation
>> http://www.centrexcc.com
>>
>>
>>
>
>-- 
>Please see the official ORACLE-L FAQ:
>http://www.orafaq.net
>-- 
>Author: GovindanK
>  INET: [EMAIL PROTECTED]
>
>Fat City Network Services-- 858-538-5051
>http://www.fatcity.com
>San Diego, California-- Mailing list and
>web hosting services
>To REMOVE yourself from this mailing list, send an
>E-Mail message
>to: [EMAIL PROTECTED] (note EXACT spelling of
>'ListGuru') and in
>the message BODY, include a line containing: UNSUB
>ORACLE-L
>(or the name of mailing list you want to be removed
>from).  You may
>also send the HELP command for other information
>(like subscribing).
>---
>--


Regards,

Stephane Faroult
Oriole
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Stephane Faroult
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


Re: how can I see which database I am logged into without

2003-09-10 Thread GovindanK
How about SELECT ORA_DATABASE_NAME FROM DUAL;

HTH
GovindanK

> select sys_context('USERENV','DB_NAME') from ;
>
> At 10:49 AM 9/10/2003 -0800, you wrote:
>>hi.
>>
>>I think there was a dbms package to get some of
>>the environment variables for a session, but I can't
>>remember anyhting specific. If someone know what I'm
>>talking about and has any details, please Email me or
>>post here
>>
>>thanks
>>
>>Gene
>
> Wolfgang Breitling
> Oracle7, 8, 8i, 9i OCP DBA
> Centrex Consulting Corporation
> http://www.centrexcc.com
>
>
>

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: GovindanK
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


RE: how can I see which database I am logged into without v$instance and v$database

2003-09-10 Thread Jacques Kilchoer
> -Original Message-
> From: Olga Gurevich [mailto:[EMAIL PROTECTED]
> 
> I think there was a dbms package to get some of
> the environment variables for a session, but I can't
> remember anyhting specific. If someone know what I'm
> talking about and has any details, please Email me or
> post here


Oracle9i SQL Reference Release 2 (9.2)
Part Number A96540-01
Functions, 122 of 177: SYS_CONTEXT
...
Table 6-2  Predefined Parameters of Namespace USERENV
...
(parameter, return value, return length (bytes))
DB_DOMAIN
 Domain of the database as specified in the DB_DOMAIN initialization parameter. 256

DB_NAME
 Name of the database as specified in the DB_NAME initialization parameter. 30
...
HOST
 Name of the host machine from which the client has connected. 54

INSTANCE
 The instance identification number of the current instance. 30

e.g.

select
   sys_context ('userenv', 'db_domain') as db_domain,
   sys_context ('userenv', 'db_name') as db_name,
   sys_context ('userenv', 'host') as host,
   sys_context ('userenv', 'instance') as instance
 from dual ;
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Jacques Kilchoer
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


Re: how can I see which database I am logged into without v$instance and v$database

2003-09-10 Thread Tanel Poder
Olga,

There are userenv and sys_context functions. Describe sys.standard package
to get more information. Or if you want to be really advanced, go and read
the documentation ;)

Tanel.

- Original Message - 
To: "Multiple recipients of list ORACLE-L" <[EMAIL PROTECTED]>
Sent: Wednesday, September 10, 2003 9:49 PM
and v$database


> hi.
>
> I think there was a dbms package to get some of
> the environment variables for a session, but I can't
> remember anyhting specific. If someone know what I'm
> talking about and has any details, please Email me or
> post here
>
> thanks
>
> Gene
>
> __
> Do you Yahoo!?
> Yahoo! SiteBuilder - Free, easy-to-use web site design software
> http://sitebuilder.yahoo.com
> -- 
> Please see the official ORACLE-L FAQ: http://www.orafaq.net
> -- 
> Author: Olga Gurevich
>   INET: [EMAIL PROTECTED]
>
> Fat City Network Services-- 858-538-5051 http://www.fatcity.com
> San Diego, California-- Mailing list and web hosting services
> -
> To REMOVE yourself from this mailing list, send an E-Mail message
> to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
> the message BODY, include a line containing: UNSUB ORACLE-L
> (or the name of mailing list you want to be removed from).  You may
> also send the HELP command for other information (like subscribing).
>


-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Tanel Poder
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


Re: how can I see which database I am logged into without

2003-09-10 Thread Wolfgang Breitling
select sys_context('USERENV','DB_NAME') from ;

At 10:49 AM 9/10/2003 -0800, you wrote:
hi.

I think there was a dbms package to get some of
the environment variables for a session, but I can't
remember anyhting specific. If someone know what I'm
talking about and has any details, please Email me or
post here
thanks

Gene
Wolfgang Breitling
Oracle7, 8, 8i, 9i OCP DBA
Centrex Consulting Corporation
http://www.centrexcc.com
--
Please see the official ORACLE-L FAQ: http://www.orafaq.net
--
Author: Wolfgang Breitling
 INET: [EMAIL PROTECTED]
Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


RE: how can I see which database I am logged into without v$insta

2003-09-10 Thread Gorbounov,Vadim
Olga, 

Does select * from global_name ; do the trick?


-Original Message-
Sent: Wednesday, September 10, 2003 2:50 PM
To: Multiple recipients of list ORACLE-L
v$instance and v$database


hi.

I think there was a dbms package to get some of
the environment variables for a session, but I can't
remember anyhting specific. If someone know what I'm
talking about and has any details, please Email me or
post here

thanks

Gene

__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Olga Gurevich
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Gorbounov,Vadim
  INET: [EMAIL PROTECTED]

Fat City Network Services-- 858-538-5051 http://www.fatcity.com
San Diego, California-- Mailing list and web hosting services
-
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).