dcsimg
How to connect a Remote Database with Servlet and JDBC?
2 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   KK_Wan
Posted On:   Thursday, March 7, 2002 09:23 PM

I know how to connect the database if it is on the same machine or network of the servlet.
HOwever, how can i connect a remote database, if i already got is IP address.

Re: How to connect a Remote Database with Servlet and JDBC?

Posted By:   Phong_Nguyen  
Posted On:   Friday, March 8, 2002 05:40 AM

Sure you can, but it is a lot of works and you must use java.rmi objects

For that just creat a client and a server (looks differents tutorials about it) and creates a CachedRowSet (javax.sql) to send ResultSet via RMI

But you need to implement you owns methods in the interface to access standards methods of java.sql.

Re: How to connect a Remote Database with Servlet and JDBC?

Posted By:   Bozidar_Dangubic  
Posted On:   Friday, March 8, 2002 05:39 AM

so you know how to connect to local database. then connecting the remote database should not be a problem. just specify a remote url where the database is located instead of local one.
About | Sitemap | Contact