在ClassPath路径创建log4j2.xml配置文件,增加如下日志配置: ... ...
分类:
其他好文 时间:
2017-06-21 22:59:09
阅读次数:
296
在web项目启动时会自动的加载wen.xml文件,在web3.0出现新特性,无需再配置web.xml,使用注解的方式来启动需要的项目文件,下面请看代码。使用的是mybatis,springmvc,spring,作为示例.1.首先通过注解方式让MVC的核心类DispatcherServlet生效,并拦 ...
分类:
Web程序 时间:
2017-06-21 18:26:33
阅读次数:
231
0.在Intellij IDEA创建maven项目 1. 在maven项目的pom.xml 添加mybatis-generator-maven-plugin 插件 2. 在maven项目下的src/main/resources 目录下建立名为 generatorConfig.xml的配置文件,作为m ...
分类:
其他好文 时间:
2017-06-21 14:12:40
阅读次数:
449
0 说明 Mybatis使用 MyBatis-Spring 类库来集成spring框架 MyBatis-Spring官网 http://www.mybatis.org/spring/index.html MyBatis-Spring是一个MyBatis框架的子模块,可以提供和Spring框架的无缝集 ...
分类:
编程语言 时间:
2017-06-21 13:56:18
阅读次数:
183
1、在已有的eclipse快捷方式,拷贝出一个副本,将该副本改成自己自定义的名称。 改名后:eclipse-mybatis 2、给eclipse-mybatis这个快捷方式,指定一个workspace。具体是在属性加上 -data workspace文件目录路径,如:-data D:\workspa ...
分类:
系统相关 时间:
2017-06-21 00:23:51
阅读次数:
183
因为在用到spring boot + mybatis的项目时候,经常发生访问接口卡,服务器项目用了几天就很卡的甚至不能访问的情况,而我们的项目和数据库都是好了,考虑到可能时数据库连接的问题,所以我打算引入数据池,引入数据池的时候找来找去,比较了当前两个最火的数据池,阿里的druid和HikariCP ...
分类:
编程语言 时间:
2017-06-20 22:31:09
阅读次数:
272
警告: No data sources are configured to run this SQL and provide advanced code assistance. Disable this inspection via problem menu (Alt+Enter). more... ...
分类:
其他好文 时间:
2017-06-20 22:20:23
阅读次数:
3105
mybatis 调用执行存储过程 mysql 声明建立存储过程 删除 在mysql中调用 -- 声明定义存储过程 delimiter $$ create procedure delbook(id int) begin delete from book where book_id=id; end$$ ...
分类:
其他好文 时间:
2017-06-20 20:18:32
阅读次数:
277
mybatis 执行JDBC SQL语句第一方式 使用mybatis 预留的Connection接口 this.ss 就是 SqlSession 会话 @Test public void s1() throws SQLException { Connection conn = this.ss.get ...
分类:
数据库 时间:
2017-06-20 20:16:51
阅读次数:
350
mybatis 核心配置文件 src/main/resources/db.properteis jdbc.driver=com.mysql.jdbc.Driver jdbc.url=jdbc:mysql://localhost:3306/db?useSSL=true&useUnicode=true& ...
分类:
其他好文 时间:
2017-06-20 20:14:07
阅读次数:
136