63 lines
2.1 KiB
XML
63 lines
2.1 KiB
XML
<?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.hivekion.environment.mapper.SimtoolEbeMapper">
|
|
<resultMap id="DMSimtoolEbe" type="com.hivekion.environment.entity.SimtoolEbe">
|
|
<result property="ebeLon" column="EBE_LON"/>
|
|
<result property="ebeLat" column="EBE_LAT"/>
|
|
<result property="ebeR" column="EBE_R"/>
|
|
<result property="scenarioUuid" column="SCENARIO_UUID"/>
|
|
<!-- 其他字段 -->
|
|
</resultMap>
|
|
<select id="list" resultType="com.hivekion.environment.entity.SimtoolEbe" parameterType="com.hivekion.environment.entity.SimtoolEbe" >
|
|
SELECT
|
|
@rownum := @rownum + 1 AS seq,
|
|
*
|
|
FROM (
|
|
SELECT * FROM tbl_simtool_ebe
|
|
<where>
|
|
<if test="scenarioUuid != null and scenarioUuid !='' ">
|
|
and scenario_uuid =#{scenarioUuid}
|
|
</if>
|
|
</where>
|
|
order by id asc ) t, ( SELECT @rownum := #{start} ) r limit
|
|
#{start},#{pageSize}
|
|
</select>
|
|
|
|
<select id="count" resultType="java.lang.Long" parameterType="com.hivekion.environment.entity.SimtoolEbe" >
|
|
select count(id) from tbl_simtool_ebe
|
|
<where>
|
|
<if test="scenarioUuid != null and scenarioUuid !='' ">
|
|
and scenario_uuid =#{scenarioUuid}
|
|
</if>
|
|
</where>
|
|
|
|
</select>
|
|
|
|
<select id="list" resultMap="DMSimtoolEbe" parameterType="com.hivekion.environment.entity.SimtoolEbe" databaseId="dm">
|
|
select
|
|
t.seq,
|
|
t.*
|
|
FROM (
|
|
SELECT
|
|
ROW_NUMBER() OVER (ORDER BY id ASC) AS seq,
|
|
a.*
|
|
FROM tbl_simtool_ebe a
|
|
<where>
|
|
<if test="scenarioUuid != null and scenarioUuid !='' ">
|
|
and scenario_uuid =#{scenarioUuid}
|
|
</if>
|
|
</where>
|
|
) t
|
|
WHERE t.seq > #{start} AND t.seq <= (#{start} + #{pageSize})
|
|
</select>
|
|
|
|
<select id="count" resultType="java.lang.Long" parameterType="com.hivekion.environment.entity.SimtoolEbe" databaseId="dm">
|
|
select count(id) from tbl_simtool_ebe
|
|
<where>
|
|
<if test="scenarioUuid != null and scenarioUuid !='' ">
|
|
and scenario_uuid =#{scenarioUuid}
|
|
</if>
|
|
</where>
|
|
</select>
|
|
</mapper>
|