problem With MySql , Java and charset
Posted by: Jan Souza
Date: October 05, 2004 11:42AM

Hi all,

I am having some problems with Mysql and Java.
My servlet get a parameter from a HTML form and insert it on a MySql DB and then get it back.
When the parameter come with out an especial character, there is no problem. But when it comes with an especial character (é, á, â, ã,..) there are problems to get it. The parameter comes with a "?" (question mark) replacing the especial character;
Ex)

(parameter) pelé --> (servlet before insert on bank) --> pelé (bank) pelé --> (servlet after bank) --> pel?

I think it is some problem with the driver that I am using to conect to mysql. (I am using Connector/J 3.0 )
Because when I print the paramenter inside the servlet before insert on the bank it is ok.
But once that I insert it on the bank and select it prints the "?"
If I use some client Mysql to see how it is on the bank, I see that it is correct ...pelé.

Does anybody knows what I am doing wrong ?
I need help !
Thanks

Options: ReplyQuote


Subject
Written By
Posted
problem With MySql , Java and charset
October 05, 2004 11:42AM
October 06, 2004 08:34AM
October 19, 2004 12:06AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.