wood burning stoves 2.0*
The moose likes JDBC and the fly likes can i connect to a db2 server  which is not in my local net work using net driver? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Databases » JDBC
Bookmark "can i connect to a db2 server  which is not in my local net work using net driver?" Watch "can i connect to a db2 server  which is not in my local net work using net driver?" New topic
Author

can i connect to a db2 server which is not in my local net work using net driver?

niranjan pulipati
Greenhorn

Joined: Jul 04, 2001
Posts: 4
Hai,
I have a doubt.. I have my application server on my system with some JSP pages. My client wants database in a remote system which is not in my local network. Can i do that for a db2 database with net driver.? if so how?
Actually the same can be done using mysql database. IN mySql even if the database is anywhere in internet by just giving access to a specific IP Address we can connect to that database anywhere.
Is the same possible with db2 net driver?
Thanks & Regards
Niranjan
Robert Brunner
Ranch Hand

Joined: Jul 18, 2001
Posts: 49
What you describe is a manifestation of the n-tier approach. There is no rule that the middle-tier needs to be co-located with the back-end. You can have the database server anywhere, as long as you configure the JDBC appropriately (i.e., use the full DNS name for the database server in the JDBC URL) your code will work. You might have to deal with firewall or security issues, but that is straightforward.
To understand the JDBC URL syntax for the appropriate JDBC driver, read the driver documentation.
 
GeeCON Prague 2014
 
subject: can i connect to a db2 server which is not in my local net work using net driver?