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: connecting to Oracle without using TNSNAMES.ORA

Re: connecting to Oracle without using TNSNAMES.ORA

From: Kenneth C Stahl <BlueSax_at_Unforgettable.com>
Date: 2000/05/18
Message-ID: <3923EF75.9783E64F@Unforgettable.com>#1/1

DNP wrote:
>
> Doubt it - Net8 needs other information that is found in its config
> files. Or more accurately; when you need Net8 to do some sophisticated
> work for you (e.g. Advanced Networking Option (ANO)) then it stores most
> of its config parameters in these files.
>
> Besides - these files offer you another 'abstraction layer' above your
> actual IP addresses etc.
>
> Basically you can create your own naming system for oracle databases,
> through the use of service names / connect strings.
>
> This may not sound like much but anything that avoids you having to
> hard-code things like IP addresses on the client side will always be
> worth it.
>
> David P.

It is done like this:

sqlplus system/manager@(DESCRIPTION=(ADDRESS=(COMMUNITY=tcp.world) (PROTOCOL=TCP)(Host=255.255.255.255)(Port=1521))(CONNECT_DATA=(SID=mysid)))

Simply substitute a real ip address (or a host name) in place of the dummy ip address change the port number to the port number of the listener if it is not 1521 and change the name of the sid to whatever is your real sid.

Notice that this is simply using the same information that is contained in tnsnames.ora, so I'm not sure why you would want this cumbersome syntax when you can just simply use a service name in tnsnames.ora that already has this information assigned. Received on Thu May 18 2000 - 00:00:00 CDT

Original text of this message

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