怎么回事?太怪了 对mysql 使用select * from biao where bia2 like '人' 出错 用like %xy% 语句会搜索出 不还有xy的记录 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 这是中英文转换问题,具体该怎么解决我不清楚,我昨晚也碰到过like '%何%'结果将"何" 与"宋"都查出来了 useUnicode=true&characterEncoding=8859_1加到url后了吗? yun15291li(秋飞意) 你说的是什么意思呀?请教 我终于明白了 谢谢你的提醒//******************************************原来我用 String myuser="root"; String mypasswd="rootadmin--"; String sDBDriver="org.gjt.mm.mysql.Driver"; String sConnStr="jdbc:mysql://localhost:3306/kfq";。。 try {conn = DriverManager.getConnection(sConnStr,myuser,mypasswd); }catch(SQLException e){ e.printStackTrace(); }。连接数据库//********************************************现在改为 String sDBDriver="org.gjt.mm.mysql.Driver"; String URL="jdbc:mysql://localhost:3306/kfq?user=root&password=root&useUnicode=true&characterEncoding=8859_1"; ....try {conn = DriverManager.getConnection(URL); }catch(SQLException e){ e.printStackTrace(); }....就不出错了 关于mysql按日期分区 SQL_CALC_FOUND_ROWS 主要用于什么方面 创建外键失败,不知原因 Table storage engine for 't_teacher' doesn't have this option 索引大小有什么用途? mysql.sock 和mysqld.sock的疑问 mysql数据库图片插入和读取 有关MYSQL数据库的集群问题 大家帮下忙,菜鸟问题! mysql日期型加法如何做?? vb、linux与mysql JDBC的驱动那里有下?(MySql的,当然最好还有其他的数据库的)谢谢各位高手!
like '%何%'
结果将"何" 与"宋"都查出来了
加到url后了吗?
//******************************************
原来我用 String myuser="root";
String mypasswd="rootadmin--";
String sDBDriver="org.gjt.mm.mysql.Driver";
String sConnStr="jdbc:mysql://localhost:3306/kfq";
。。
try {conn = DriverManager.getConnection(sConnStr,myuser,mypasswd);
}catch(SQLException e){
e.printStackTrace();
}
。连接数据库//********************************************现在改为
String sDBDriver="org.gjt.mm.mysql.Driver";
String URL="jdbc:mysql://localhost:3306/kfq?user=root&password=root&useUnicode=true&characterEncoding=8859_1";
....
try {conn = DriverManager.getConnection(URL);
}catch(SQLException e){
e.printStackTrace();
}
....
就不出错了