• 简单分析下mybatis中mapper文件中小知识


    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
    <mapper namespace="*.mapper.IEInvoiceNumPoolMapper" > //namespace中对应的是dao层接口,具体到接口名
    <resultMap id="BaseResultMap" type="*.EInvoice.EINumPoolDTO" > //resultMmap中对应的是实体类,具体到实体类名
    <id column="EINUMPOOLID" property="EINUMPOOLID" jdbcType="VARCHAR" />
    <result column="ADMDIVID" property="ADMDIVID" jdbcType="BIGINT" />
    <result column="BillTypeID" property="BillTypeID" jdbcType="BIGINT" />
    <result column="YEAR" property="YEAR" jdbcType="VARCHAR" />
    <result column="STARTEINUM" property="STARTEINUM" jdbcType="VARCHAR" />
    <result column="ENDEINUM" property="ENDEINUM" jdbcType="VARCHAR" />
    <result column="CurrentlyNum" property="CurrentlyNum" jdbcType="VARCHAR" />
    </resultMap>
    <sql id="Base_Column_List" >
    EINUMPOOLID, ADMDIVID, BillTypeID,YEAR,STARTEINUM,ENDEINUM,CurrentlyNum
    </sql>
    <select id="selectByYear" resultMap="BaseResultMap" parameterType="java.lang.String" > //id对应的就是dao层接口里的方法名,必须一一对应
    select
    <include refid="Base_Column_List" />
    from t_fseinumpool
    where YEAR= #{year}
    </select>
    简单写一下,防止以后遗忘
  • 相关阅读:
    移动端meta标签
    document.ready 和 window.onload
    axios 源码分析
    vue 中的 el
    安卓和Ios 手机兼容性
    一些移动端问题
    Python 局部变量与全局变量
    Linux常用命令大全(非常全!!!)
    Python_爬虫_基础
    linux 常用命令
  • 原文地址:https://www.cnblogs.com/lovefaner/p/9687463.html
Copyright © 2020-2023  润新知