zoukankan      html  css  js  c++  java
  • MyBatis 配置文件

    MyBatis 配置文件

    记不住上边的跟标签就复制吧!

    mybatis-config.xml

    <?xml version="1.0" encoding="UTF-8" ?>
    <!DOCTYPE configuration
            PUBLIC "-//mybatis.org//DTD Config 3.0//EN"
            "http://mybatis.org/dtd/mybatis-3-config.dtd">
    <configuration>
        <settings>
            <setting name="cacheEnable" value="true"/>
        </settings>
    </configuration>
    

    mapper.xml

    <!DOCTYPE mapper
            PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
            "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
    
    <mapper namespace="com.fujie.springcloud.pojo.Dept">
        <resultMap type="com.fujie.springcloud.pojo.Dept" id="deptMap">
            <id column="dept_id" property="deptId"/>
            <result column="dept_name" property="deptName"/>
            <result column="dept_resource" property="deptSource"/>
        </resultMap>
    
    </mapper>
    
  • 相关阅读:
    Spring----Day03
    Spring----Day02
    python
    python
    python
    python
    python
    python
    python
    python
  • 原文地址:https://www.cnblogs.com/faddei/p/13702549.html
Copyright © 2011-2022 走看看