北京经济技术开发区经开区虚拟城市项目-【后端】-服务,Poi,企业,地块等定制接口
13693261870
2023-10-07 a093b470d5f9ce57c05ad610312d4af69688a18b
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<?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.smartearth.poiexcel.mapper.EntMapper">
    <select id="selectByName" resultType="com.smartearth.poiexcel.entity.EntEntity">
        select *
        from smart_earth.yz_qiyexinxi
        <where>
            <if test="name != null">
                upper(entName) like #{name} or upper(address) like #{name}
            </if>
        </where>
        order by entName
        limit 10;
    </select>
 
    <select id="selectCount" resultType="java.lang.Integer">
        select count(*)
        from smart_earth.yz_qiyexinxi
        where x is null or y is null;
    </select>
 
    <select id="selectByPage" resultType="com.smartearth.poiexcel.entity.EntEntity">
        select *
        from smart_earth.yz_qiyexinxi
        where x is null or y
        order by id
        limit #{limit} offset #{offset};
    </select>
 
    <update id="update">
        update smart_earth.yz_qiyexinxi
        set x=#{x},y=#{y}
        where id=#{id};
    </update>
 
    <update id="updates">
        <foreach collection="list" item="item" index="index">
            update smart_earth.yz_qiyexinxi set x=#{item.x},y=#{item.y} where id=#{item.id};
        </foreach>
    </update>
</mapper>