resources mybatis-config.xml <?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE configuration PUBLIC "-//mybatis.org//DTD Config 3.0//EN" "http://mybatis.org/dtd/mybat…
1、添加 <!--int insertUser();--> <insert id="insertUser"> insert into t_user values(null,'admin','123456',23,'男') </insert> 2、删除 <!--int deleteUser();--> …
核心配置文件中的标签必须按照固定的顺序: properties?,settings?,typeAliases?,typeHandlers?,objectFactory?,objectWrapperFactory?,reflectorFactory?,plugins?,environments?,databaseIdProvider?,mappers…
pom.xml <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http:…
1、开发环境 IDE:idea 2022.3 构建工具:maven 3.8.1 MySQL版本:MySQL 8.0 MyBatis版本:MyBatis 3.5.7 2、创建maven工程 a>打包方式:jar b>引入依赖 <!-- Mybatis核心 --> <dependency> <groupId>org.mybatis&l…