标签:
数据库字段和对象属性的映射
<?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="com.daoPerson"> <resultMap type="com.entity.ettPerson" id="Person"> <result property="ID" column="ID" /> <result property="name" column="name" /> </resultMap> <insert id="add" parameterType="com.ettPerson"> INSERT INTO t (ID,name ) values(#{ID},#{name}) </insert> </mapper>
标签:
原文地址:http://www.cnblogs.com/cb168/p/4721149.html