|
|
@ -3,14 +3,15 @@ |
|
|
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
|
|
|
<mapper namespace="com.zc.business.mapper.DcTollStationStatisticsDataMapper"> |
|
|
|
<resultMap type="map" id="countMap"> |
|
|
|
<resultMap type="com.zc.business.domain.DcTollStationStatisticsDataMap" id="DcTollStationStatisticsDataMap"> |
|
|
|
<result property="id" column="id"/> |
|
|
|
<result property="facilityName" column="facility_name"/> |
|
|
|
<result property="toll_station_code" column="toll_station_code"/> |
|
|
|
<result property="traffic_volume" column="traffic_volume"/> |
|
|
|
<result property="period_type" column="period_type"/> |
|
|
|
<result property="access_type" column="access_type"/> |
|
|
|
<result property="statisticalDate" column="statisticalDate"/> |
|
|
|
<result property="tollStationCode" column="toll_station_code"/> |
|
|
|
<result property="trafficVolume" column="traffic_volume"/> |
|
|
|
<result property="periodType" column="period_type"/> |
|
|
|
<result property="accessType" column="access_type"/> |
|
|
|
<result property="statisticalDate" column="statistical_date"/> |
|
|
|
<result property="stakMark" column="stake_mark"/> |
|
|
|
</resultMap> |
|
|
|
<!-- 插入或更新交通路段数据 --> |
|
|
|
<insert id="insertOrUpdate" parameterType="com.zc.business.domain.DcTollStationStatisticsData"> |
|
|
@ -100,26 +101,26 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
</select> |
|
|
|
|
|
|
|
|
|
|
|
<select id="TollBoothStatistics" resultMap="countMap" resultType="map" > |
|
|
|
SELECT |
|
|
|
fa.facility_name, |
|
|
|
fa.stake_mark, |
|
|
|
dt.id, |
|
|
|
dt.access_type, |
|
|
|
dt.period_type, |
|
|
|
dt.traffic_volume, |
|
|
|
dt.toll_station_code, |
|
|
|
dt.statistical_date |
|
|
|
FROM |
|
|
|
dc_facility AS fa |
|
|
|
LEFT JOIN |
|
|
|
dc_toll_station_statistics_data AS dt |
|
|
|
ON |
|
|
|
fa.facility_code = dt.toll_station_code |
|
|
|
AND DATE(dt.statistical_date) = DATE(#{startDate}) |
|
|
|
AND dt.period_type = #{periodType} |
|
|
|
AND dt.access_type = #{accessType} |
|
|
|
WHERE fa.facility_type = 1 |
|
|
|
</select> |
|
|
|
<select id="TollBoothStatistics" parameterType="string" resultType="DcTollStationStatisticsDataMap" > |
|
|
|
SELECT |
|
|
|
fa.facility_name, |
|
|
|
fa.stake_mark, |
|
|
|
dt.id, |
|
|
|
dt.access_type, |
|
|
|
dt.period_type, |
|
|
|
dt.traffic_volume, |
|
|
|
dt.toll_station_code, |
|
|
|
dt.statistical_date |
|
|
|
FROM |
|
|
|
dc_facility AS fa |
|
|
|
LEFT JOIN |
|
|
|
dc_toll_station_statistics_data AS dt |
|
|
|
ON |
|
|
|
fa.facility_code = dt.toll_station_code |
|
|
|
AND DATE(dt.statistical_date) = DATE(#{startDate}) |
|
|
|
AND dt.period_type = #{periodType} |
|
|
|
AND dt.access_type = #{accessType} |
|
|
|
WHERE fa.facility_type = 1 |
|
|
|
</select> |
|
|
|
|
|
|
|
</mapper> |
|
|
|