- 博客(11)
- 资源 (2)
- 收藏
- 关注
原创 java分割字符
String[] strArray = aString.split(",");//可以用split来分割,具体用法视项目情况而定
2017-05-11 20:25:16 358
原创 字符串转换成int
int id1 = Integer.parseInt("str");//接收str字符串int id = Integer.parseInt("10");
2017-05-11 20:21:31 899
原创 java.lang.Exception: No tests found matching Method test5(com.crosudd.test.TestMybatis) from org.jun
mybatis异常:java.lang.Exception: No tests found matching Method test5(com.crosudd.test.TestMybatis) from org.junit.internal.requests.ClassRequest@1565ec2junit测试 测试方法上未加@Test注解,加上去就可以了,提示大家,编码过程中一定
2017-05-09 20:49:57 1112
原创 SLF4J: Class path contains multiple SLF4J bindings.
logback.xml 和log4j.properties两种都是打印输出日志,方便查找日志,在个人两种使用比较,倾向于logback.xm,这种显然要好于后者。建议用logback.xml,视个人(公司)情况。出现这种情况是引用包冲突,slf4j提供了一个接口,log4j或logback都会引用这个借口,也不会影响日志的打印,如果用强迫症的可以认真查找冲突包,去掉冲突包。个人失去掉了这个包。
2017-05-04 20:46:55 1211
原创 web.xml <async-supported>true</async-supported>报错
web.xml 经过servlet版本不断更新,现在为3.0的版本,如果在配置web.xml的报错,就要看你的版本是2.0还是3.0,找相对应的版本,就不会出现这种错误。我的错误解决是将:改之前:<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
2017-05-04 20:34:15 474
原创 web.xml初始化过程
大学学servlet这部分的老师讲了web.xml的加载过程,当时不懂也不理解,配置过程也是随意配置,后来在公司实际项目搭建项目过程,开始认识到这些问题,web.xml加载过程context-param >> listener >> filter >> servlet和mybatis的配置文件 --> contextConfigLocation classpath:spr
2017-05-04 20:10:58 372
原创 mybatis 打印执行sql语句l
### set log levels ####log4j.rootLogger = debug , stdout , D , Elog4j.rootLogger=info , stdout , D#定义日志输出目的地为控制台### output to the console ###log4j.appender.stdout=org.apache.log4j.ConsoleAppende
2017-05-04 18:42:00 623
原创 Caused by: java.sql.SQLSyntaxErrorException: Unknown column name in field list
开发中查询时 出现这种错误 Caused by: java.sql.SQLSyntaxErrorException: Unknown column 'name' in 'field list' 解决方法: mybatis 的xml文件中出现了与数据库表中的字段不匹配。提醒大家此情况在开发中注意!
2017-05-04 18:35:50 34186 8
原创 Cannot instantiate test(s): java.lang.SecurityException: Prohibited package name: java.com.crosudd.t
异常错误:Cannot instantiate test(s): java.lang.SecurityException: Prohibited package name: java.com.crosudd.test是在测试包:包名出现了java.com.crosudd.test java开头,应该改为 com.crosudd.test 把Java去掉 就可以了写测试类了。个人
2017-05-04 09:10:36 10285 12
原创 异常:java.sql.SQLException: The server time zone value '?й???????' is unrecognized or represents more
软件开发,为了满足开发的需要,jar包版本的更新或bug的修复,会造成 版本不兼容,出现新问题,程序员就是为解决问题出现的,一句话就是我们爱折腾,乐此不彼。异常错误:java.sql.SQLException: The server time zone value '?й???????' is unrecognized or represents more than one time zone
2017-05-04 09:01:46 24007 14
原创 Loading class `com.mysql.jdbc.Driver'. This is deprecated. The new driver class is `com.mysql.cj.jdb
异常错误:Loading class `com.mysql.jdbc.Driver'. This is deprecated. The new driver class is `com.mysql.cj.jdbc.Driver'. The driver is automatically registered via the SPI and manual loading of the driver ...
2017-05-04 08:55:40 145311 35
JDK6u45 64
2015-11-03
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人