Re: JDBC and oracle

From: Jon Conradt <jon_at_gallup.com>
Date: 1997/05/06
Message-ID: <01bc5a2d$d6d62d80$02c0f7c6_at_jonc>#1/1


Andrew C. Risehnoover <qball_at_ti.com> wrote in article <336E5D83.AC17292C_at_ti.com>...
> I am trying to develop a webased application that will connect to an
> oracle database and make calls to some stored procedures. I got the
> JDBC drivers from oracle, but in the documentation it said these could
> only be used with stand alone applications and would not work from
> within and applet. The databases will be internal in the beginning, but
> possibly external in the long run. I did not want to resort to straight
> ODBC calls because of speed. The application has been written in
> OraPerl, and I was hoping I could get a chance to re release it in Java.
>

Because you are talking to an Oracle database you could take advantage of the Oracle WebServer 3.0 api for Java and move the logic to the server, leaving the applet to maintain the UI. This is how Oracle does their Developer/2000 port to Java.

Because you can then talk to the CGI(WRB) process via port 80 using standard HTTP you do not have to worry about firewalls. This has the added benefit of putting you in a three-tier architecture where you are free to change the database (say to Oracle 8 or SQL Server) or the program logic without having to change the applet.

> How would I connect to a database from within the applet?
>

From within an applet you can connect to a database using JDBC if the applet was loaded from a webserver on the same machine as the database. This would require a Type 4 driver which is available from http://www.weblogic.com among others for Oracle. Oracle says they will release their thin client JDBC driver for 1.1.x around the same time as Oracle 8's release (June 24th). For more information on Type 4 and other JDBC drivers you should visit the Javasoft web site.

> Is contact with external databases going to conflict with Java internal
> security procedures?

An applet should be allowed to talk to a database as long as the applet came from that same machine. With signed applets around the corner you will be able to losen this restriction.

Jon Received on Tue May 06 1997 - 00:00:00 CEST

Original text of this message