解决MySQL中文显示问题的方法

public String getStr(Object s)
{
    String str
=String.valueOf(s);
    
try
    
{
      
byte b[]=str.getBytes("ISO-8859-1");
      str
=new String(b);
      
return str;
    }

    
catch(Exception e)
    
{
        e.printStackTrace;
        
return null;}

}
 


posted on 2007-04-18 21:30 我为J狂 阅读(597) 评论(0)  编辑  收藏 所属分类: DataBase


只有注册用户登录后才能发表评论。


网站导航:
 
<2024年4月>
31123456
78910111213
14151617181920
21222324252627
2829301234
567891011

导航

统计

常用链接

留言簿(11)

随笔分类(48)

文章分类(29)

常去逛逛

搜索

积分与排名

最新评论

阅读排行榜

评论排行榜