日期:2014-05-18  浏览次数:20771 次

jsp提交汉字到oracle数据库出现乱码!
我在jsp的页面表单中填写汉字   提交到oracle数据库,在数据库中出现的怎么是乱码啊??

------解决方案--------------------
用这个转一下就成
public String GBToUnicode(String strIn)
{
String strOut = null;
if(strIn == null || (strIn.trim()).equals( " "))return strIn;
try{
byte[] b = strIn.getBytes( "ISO8859_1 ");
strOut = new String(b, "GBK ");
}
catch(Exception e)
{}
return strOut;
}