mtbatis 模糊查询

 

 

<resultMap id="getallList" type="com.example.demo.pojo.node" autoMapping="true">
    <result property="name" column="NameZh"></result>
    <result property="field" column="ResearchField"></result>

</resultMap>

<!--resultType="com.example.demo.pojo.node"-->

<select id="findall"  resultMap="getallList">
    select s.NameZh  ,s.ResearchField   from researcher_basic_info_copy5 s

    <where>
        <if test="text != null">
            and s.ResearchField like  '%${text}%'
        </if>
    </where>

</select>

 

 

相关文章:

  • 2021-12-19
  • 2021-04-07
  • 2021-09-12
  • 2021-10-04
  • 2021-04-06
  • 2021-12-29
  • 2021-04-02
猜你喜欢
  • 2021-04-13
  • 2021-12-18
  • 2021-05-15
  • 2021-12-10
  • 2021-08-23
相关资源
相似解决方案