is it possible to use ip:port instead of sid for oracleconnection?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

for example:

connectionstr="DATA SOURCE=192.168.1.11:1521;UID=bnd;PWD=bnd;" instead of
connectionstr="DATA SOURCE=sid;UID=bnd;PWD=bnd;"

new oracleconnection(connectionstr);

is it ok, and what is the format of data source?
 
Hi,

I haven't seen such a thing in use myself, because all the IP address + port
numbers are usually stored in the tnsname.ora file, IINM, so it would be the
right way to connect using the name, instead of the IP address.

-Altaf
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top