Database connectivity using Applets

Hi,

I have an applet which has to connect to the database and then fetch the result. THis applet is embedded in the HTML. This does not seem to work and it throws some security exceptions. I even tried policy files and signing of applets.

Can someone suggest a step by step process for achieving my requirement.

Thanks

Ramna

[363 byte] By [ramna21] at [2007-9-26 2:56:49]
# 1

First step is to decide if you need a signed applet for your task.

Let's say your web server is installed on a machine called sweb.

If your database server is not running on sweb and you cannot

install a port forwarder on sweb, then you should use a signed

applet ( the port forwarder solution isn't quite simple and

it's another subject ).

I was able to connect my applet to a database ( and ofcourse

fetch some results ) just by following the JDBC Tutorial.

But in my case it was the simple case: I had the database server

on the same machine as the web server.

Now, if you are in the second case, that is you are using

signed applets, you should search+read previous posts in

http://forums.java.sun.com about signed applets.

> This does not seem to work and it throws

> some security exceptions. I even tried policy files

> and signing of applets.

Maybe it was a good idea to post that exception too.

best regards,

uly

uly at 2007-6-29 10:48:15 > top of Java-index,Security,Signed Applets...
# 2

i hope you can post the exception.i think it may be the security exception.

like the reply upstair,if the webServer and the databaseServer is the same,you should do nothing only connect the databaseServer using JDBC and fetch the result.but if they are differ server,you should use the digital sign to let additional socket connection to the databaseServer.please see the individual tutorial

best regards

pepper_dog999 at 2007-6-29 10:48:15 > top of Java-index,Security,Signed Applets...