text: <?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="cn.crap.dao.mybatis.ErrorDao" >
    <resultMap id="BaseResultMap" type="cn.crap.model.Error" >
      <id column="id" property="id" jdbcType="VARCHAR" />
      <result column="errorCode" property="errorCode" jdbcType="VARCHAR" />
      <result column="errorMsg" property="errorMsg" jdbcType="VARCHAR" />
      <result column="projectId" property="projectId" jdbcType="VARCHAR" />
      <result column="createTime" property="createTime" jdbcType="TIMESTAMP" />
      <result column="status" property="status" jdbcType="TINYINT" />
      <result column="sequence" property="sequence" jdbcType="INTEGER" />
    </resultMap>
    <sql id="Example_Where_Clause" >
      <where >
        <foreach collection="oredCriteria" item="criteria" separator="or" >
          <if test="criteria.valid" >
            <trim prefix="(" suffix=")" prefixOverrides="and" >
              <foreach collection="criteria.criteria" item="criterion" >
                <choose >
                  <when test="criterion.noValue" >
                    and ${criterion.condition}
                  </when>
                  <when test="criterion.singleValue" >
                    and ${criterion.condition} #{criterion.value}
                  </when>
                  <when test="criterion.betweenValue" >
                    and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
                  </when>
                  <when test="criterion.listValue" >
                    and ${criterion.condition}
                    <foreach collection="criterion.value" item="listItem" open="(" close=")" separator="," >
                      #{listItem}
                    </foreach>
                  </when>
                </choose>
              </foreach>
            </trim>
          </if>
        </foreach>
      </where>
    </sql>
    <sql id="Update_By_Example_Where_Clause" >
      <where >
        <foreach collection="example.oredCriteria" item="criteria" separator="or" >
          <if test="criteria.valid" >
            <trim prefix="(" suffix=")" prefixOverrides="and" >
              <foreach collection="criteria.criteria" item="criterion" >
                <choose >
                  <when test="criterion.noValue" >
                    and ${criterion.condition}
                  </when>
                  <when test="criterion.singleValue" >
                    and ${criterion.condition} #{criterion.value}
                  </when>
                  <when test="criterion.betweenValue" >
                    and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
                  </when>
                  <when test="criterion.listValue" >
                    and ${criterion.condition}
                    <foreach collection="criterion.value" item="listItem" open="(" close=")" separator="," >
                      #{listItem}
                    </foreach>
                  </when>
                </choose>
              </foreach>
            </trim>
          </if>
        </foreach>
      </where>
    </sql>
    <sql id="Base_Column_List" >
      id, errorCode, errorMsg, projectId, createTime, status, sequence
    </sql>
    <select id="selectByExample" resultMap="BaseResultMap" parameterType="cn.crap.model.ErrorCriteria" >
      select
      <if test="distinct" >
        distinct
      </if>
      <include refid="Base_Column_List" />
      from error
      <if test="_parameter != null" >
        <include refid="Example_Where_Clause" />
      </if>
      <if test="orderByClause != null" >
        order by ${orderByClause}
      </if>
      <choose >
        <when test="limitStart != null and limitStart != -1 and maxResults != null and maxResults != -1" >
          limit ${limitStart} , ${maxResults}
        </when>
        <when test="limitStart != null and limitStart != -1" >
          limit ${limitStart}
        </when>
      </choose>
    </select>
    <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
      select 
      <include refid="Base_Column_List" />
      from error
      where id = #{id,jdbcType=VARCHAR}
    </select>
    <delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
      delete from error
      where id = #{id,jdbcType=VARCHAR}
    </delete>
    <delete id="deleteByExample" parameterType="cn.crap.model.ErrorCriteria" >
      delete from error
      <if test="_parameter != null" >
        <include refid="Example_Where_Clause" />
      </if>
    </delete>
    <insert id="insert" parameterType="cn.crap.model.Error" >
      
        
      
      insert into error (id, errorCode, errorMsg, 
        projectId, createTime, status, 
        sequence)
      values (#{id,jdbcType=VARCHAR}, #{errorCode,jdbcType=VARCHAR}, #{errorMsg,jdbcType=VARCHAR}, 
        #{projectId,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{status,jdbcType=TINYINT}, 
        #{sequence,jdbcType=INTEGER})
    </insert>
    <insert id="insertSelective" parameterType="cn.crap.model.Error" >
      
        
      
      insert into error
      <trim prefix="(" suffix=")" suffixOverrides="," >
        id,
        <if test="errorCode != null" >
          errorCode,
        </if>
        <if test="errorMsg != null" >
          errorMsg,
        </if>
        <if test="projectId != null" >
          projectId,
        </if>
        <if test="createTime != null" >
          createTime,
        </if>
        <if test="status != null" >
          status,
        </if>
        <if test="sequence != null" >
          sequence,
        </if>
      </trim>
      <trim prefix="values (" suffix=")" suffixOverrides="," >
        #{id,jdbcType=VARCHAR},
        <if test="errorCode != null" >
          #{errorCode,jdbcType=VARCHAR},
        </if>
        <if test="errorMsg != null" >
          #{errorMsg,jdbcType=VARCHAR},
        </if>
        <if test="projectId != null" >
          #{projectId,jdbcType=VARCHAR},
        </if>
        <if test="createTime != null" >
          #{createTime,jdbcType=TIMESTAMP},
        </if>
        <if test="status != null" >
          #{status,jdbcType=TINYINT},
        </if>
        <if test="sequence != null" >
          #{sequence,jdbcType=INTEGER},
        </if>
      </trim>
    </insert>
    <select id="countByExample" parameterType="cn.crap.model.ErrorCriteria" resultType="java.lang.Integer" >
      select count(*) from error
      <if test="_parameter != null" >
        <include refid="Example_Where_Clause" />
      </if>
    </select>
    <update id="updateByExampleSelective" parameterType="map" >
      update error
      <set >
        <if test="record.id != null" >
          id = #{record.id,jdbcType=VARCHAR},
        </if>
        <if test="record.errorCode != null" >
          errorCode = #{record.errorCode,jdbcType=VARCHAR},
        </if>
        <if test="record.errorMsg != null" >
          errorMsg = #{record.errorMsg,jdbcType=VARCHAR},
        </if>
        <if test="record.projectId != null" >
          projectId = #{record.projectId,jdbcType=VARCHAR},
        </if>
        <if test="record.createTime != null" >
          createTime = #{record.createTime,jdbcType=TIMESTAMP},
        </if>
        <if test="record.status != null" >
          status = #{record.status,jdbcType=TINYINT},
        </if>
        <if test="record.sequence != null" >
          sequence = #{record.sequence,jdbcType=INTEGER},
        </if>
      </set>
      <if test="_parameter != null" >
        <include refid="Update_By_Example_Where_Clause" />
      </if>
    </update>
    <update id="updateByExample" parameterType="map" >
      update error
      set id = #{record.id,jdbcType=VARCHAR},
        errorCode = #{record.errorCode,jdbcType=VARCHAR},
        errorMsg = #{record.errorMsg,jdbcType=VARCHAR},
        projectId = #{record.projectId,jdbcType=VARCHAR},
        createTime = #{record.createTime,jdbcType=TIMESTAMP},
        status = #{record.status,jdbcType=TINYINT},
        sequence = #{record.sequence,jdbcType=INTEGER}
      <if test="_parameter != null" >
        <include refid="Update_By_Example_Where_Clause" />
      </if>
    </update>
    <update id="updateByPrimaryKeySelective" parameterType="cn.crap.model.Error" >
      update error
      <set >
        <if test="errorCode != null" >
          errorCode = #{errorCode,jdbcType=VARCHAR},
        </if>
        <if test="errorMsg != null" >
          errorMsg = #{errorMsg,jdbcType=VARCHAR},
        </if>
        <if test="projectId != null" >
          projectId = #{projectId,jdbcType=VARCHAR},
        </if>
        <if test="createTime != null" >
          createTime = #{createTime,jdbcType=TIMESTAMP},
        </if>
        <if test="status != null" >
          status = #{status,jdbcType=TINYINT},
        </if>
        <if test="sequence != null" >
          sequence = #{sequence,jdbcType=INTEGER},
        </if>
      </set>
      where id = #{id,jdbcType=VARCHAR}
    </update>
    <update id="updateByPrimaryKey" parameterType="cn.crap.model.Error" >
      update error
      set errorCode = #{errorCode,jdbcType=VARCHAR},
        errorMsg = #{errorMsg,jdbcType=VARCHAR},
        projectId = #{projectId,jdbcType=VARCHAR},
        createTime = #{createTime,jdbcType=TIMESTAMP},
        status = #{status,jdbcType=TINYINT},
        sequence = #{sequence,jdbcType=INTEGER}
      where id = #{id,jdbcType=VARCHAR}
    </update>
  </mapper>
  