It appears that in the applet you use the POST method to send the request. But you don't send any parameters; appending parameters to the URL is what you do if you're using the GET method. You could have done some debugging in the servlet to see if the parameter was being passed; I think it isn't.
You should decide in your servlet if you want to use POST or GET, and just handle one of them. Then you should write your applet to use whichever method you designed your servlet to use.
And in the applet you should URL-encode the parameter in case it includes characters other than letters and digits. (And why do you append an empty
string to the URL? That does nothing but add confusion for the reader.)
Plenty of bad practices in the servlet too. I would at least commit the transaction and close the connection, but that's just the start.