|
|
|
|
@ -17,9 +17,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<result property="totalMarketCap" column="total_market_cap" />
|
|
|
|
|
<result property="freeCirculationCap" column="free_circulation_cap" />
|
|
|
|
|
<result property="priceChangeRate" column="price_change_rate" />
|
|
|
|
|
<result property="amplitude" column="amplitude" />
|
|
|
|
|
<result property="turnoverRate" column="turnover_rate" />
|
|
|
|
|
<result property="equalWeightAvgChangeRate" column="equal_weight_avg_change_rate" />
|
|
|
|
|
<result property="peTtm" column="pe_ttm" />
|
|
|
|
|
<result property="peTtmMedian" column="pe_ttm_median" />
|
|
|
|
|
<result property="upCount" column="up_count" />
|
|
|
|
|
@ -30,6 +27,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<result property="suspendCount" column="suspend_count" />
|
|
|
|
|
<result property="newHighFlag" column="new_high_flag" />
|
|
|
|
|
<result property="newLowFlag" column="new_low_flag" />
|
|
|
|
|
|
|
|
|
|
<result property="createTime" column="create_time" />
|
|
|
|
|
<result property="updateTime" column="update_time" />
|
|
|
|
|
</resultMap>
|
|
|
|
|
@ -37,8 +35,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<sql id="selectIndustryIndexVo">
|
|
|
|
|
select industry_index_code, industry_index_name, component_count, trade_date,
|
|
|
|
|
open_price, close_price, high_price, low_price, volume, turnover,
|
|
|
|
|
total_market_cap, free_circulation_cap, price_change_rate, amplitude,
|
|
|
|
|
turnover_rate, equal_weight_avg_change_rate, pe_ttm, pe_ttm_median,
|
|
|
|
|
total_market_cap, free_circulation_cap, price_change_rate, pe_ttm, pe_ttm_median,
|
|
|
|
|
up_count, down_count, limit_up_count, limit_down_count, no_change_count,
|
|
|
|
|
suspend_count, new_high_flag, new_low_flag, create_time, update_time
|
|
|
|
|
from t_industry_index
|
|
|
|
|
@ -99,9 +96,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<if test="totalMarketCap != null">total_market_cap,</if>
|
|
|
|
|
<if test="freeCirculationCap != null">free_circulation_cap,</if>
|
|
|
|
|
<if test="priceChangeRate != null">price_change_rate,</if>
|
|
|
|
|
<if test="amplitude != null">amplitude,</if>
|
|
|
|
|
<if test="turnoverRate != null">turnover_rate,</if>
|
|
|
|
|
<if test="equalWeightAvgChangeRate != null">equal_weight_avg_change_rate,</if>
|
|
|
|
|
<if test="peTtm != null">pe_ttm,</if>
|
|
|
|
|
<if test="peTtmMedian != null">pe_ttm_median,</if>
|
|
|
|
|
<if test="upCount != null">up_count,</if>
|
|
|
|
|
@ -112,6 +106,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<if test="suspendCount != null">suspend_count,</if>
|
|
|
|
|
<if test="newHighFlag != null">new_high_flag,</if>
|
|
|
|
|
<if test="newLowFlag != null">new_low_flag,</if>
|
|
|
|
|
|
|
|
|
|
create_time,
|
|
|
|
|
</trim>
|
|
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
|
|
@ -128,9 +123,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<if test="totalMarketCap != null">#{totalMarketCap},</if>
|
|
|
|
|
<if test="freeCirculationCap != null">#{freeCirculationCap},</if>
|
|
|
|
|
<if test="priceChangeRate != null">#{priceChangeRate},</if>
|
|
|
|
|
<if test="amplitude != null">#{amplitude},</if>
|
|
|
|
|
<if test="turnoverRate != null">#{turnoverRate},</if>
|
|
|
|
|
<if test="equalWeightAvgChangeRate != null">#{equalWeightAvgChangeRate},</if>
|
|
|
|
|
<if test="peTtm != null">#{peTtm},</if>
|
|
|
|
|
<if test="peTtmMedian != null">#{peTtmMedian},</if>
|
|
|
|
|
<if test="upCount != null">#{upCount},</if>
|
|
|
|
|
@ -141,6 +133,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<if test="suspendCount != null">#{suspendCount},</if>
|
|
|
|
|
<if test="newHighFlag != null">#{newHighFlag},</if>
|
|
|
|
|
<if test="newLowFlag != null">#{newLowFlag},</if>
|
|
|
|
|
|
|
|
|
|
NOW(),
|
|
|
|
|
</trim>
|
|
|
|
|
</insert>
|
|
|
|
|
@ -159,9 +152,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<if test="totalMarketCap != null">total_market_cap = #{totalMarketCap},</if>
|
|
|
|
|
<if test="freeCirculationCap != null">free_circulation_cap = #{freeCirculationCap},</if>
|
|
|
|
|
<if test="priceChangeRate != null">price_change_rate = #{priceChangeRate},</if>
|
|
|
|
|
<if test="amplitude != null">amplitude = #{amplitude},</if>
|
|
|
|
|
<if test="turnoverRate != null">turnover_rate = #{turnoverRate},</if>
|
|
|
|
|
<if test="equalWeightAvgChangeRate != null">equal_weight_avg_change_rate = #{equalWeightAvgChangeRate},</if>
|
|
|
|
|
<if test="peTtm != null">pe_ttm = #{peTtm},</if>
|
|
|
|
|
<if test="peTtmMedian != null">pe_ttm_median = #{peTtmMedian},</if>
|
|
|
|
|
<if test="upCount != null">up_count = #{upCount},</if>
|
|
|
|
|
@ -172,6 +162,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<if test="suspendCount != null">suspend_count = #{suspendCount},</if>
|
|
|
|
|
<if test="newHighFlag != null">new_high_flag = #{newHighFlag},</if>
|
|
|
|
|
<if test="newLowFlag != null">new_low_flag = #{newLowFlag},</if>
|
|
|
|
|
|
|
|
|
|
update_time = NOW(),
|
|
|
|
|
</trim>
|
|
|
|
|
where industry_index_code = #{industryIndexCode} and trade_date = #{tradeDate}
|
|
|
|
|
@ -184,16 +175,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<insert id="batchInsertIndustryIndex" parameterType="java.util.List">
|
|
|
|
|
insert into t_industry_index(industry_index_code, industry_index_name, component_count, trade_date,
|
|
|
|
|
open_price, close_price, high_price, low_price, volume, turnover,
|
|
|
|
|
total_market_cap, free_circulation_cap, price_change_rate, amplitude,
|
|
|
|
|
turnover_rate, equal_weight_avg_change_rate, pe_ttm, pe_ttm_median,
|
|
|
|
|
total_market_cap, free_circulation_cap, price_change_rate, pe_ttm, pe_ttm_median,
|
|
|
|
|
up_count, down_count, limit_up_count, limit_down_count, no_change_count,
|
|
|
|
|
suspend_count, new_high_flag, new_low_flag, create_time)
|
|
|
|
|
values
|
|
|
|
|
<foreach collection="list" item="item" separator=",">
|
|
|
|
|
(#{item.industryIndexCode}, #{item.industryIndexName}, #{item.componentCount}, #{item.tradeDate},
|
|
|
|
|
#{item.openPrice}, #{item.closePrice}, #{item.highPrice}, #{item.lowPrice}, #{item.volume}, #{item.turnover},
|
|
|
|
|
#{item.totalMarketCap}, #{item.freeCirculationCap}, #{item.priceChangeRate}, #{item.amplitude},
|
|
|
|
|
#{item.turnoverRate}, #{item.equalWeightAvgChangeRate}, #{item.peTtm}, #{item.peTtmMedian},
|
|
|
|
|
#{item.totalMarketCap}, #{item.freeCirculationCap}, #{item.priceChangeRate}, #{item.peTtm}, #{item.peTtmMedian},
|
|
|
|
|
#{item.upCount}, #{item.downCount}, #{item.limitUpCount}, #{item.limitDownCount}, #{item.noChangeCount},
|
|
|
|
|
#{item.suspendCount}, #{item.newHighFlag}, #{item.newLowFlag}, NOW())
|
|
|
|
|
</foreach>
|
|
|
|
|
@ -202,16 +191,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<insert id="batchUpsertIndustryIndex" parameterType="java.util.List">
|
|
|
|
|
insert into t_industry_index(industry_index_code, industry_index_name, component_count, trade_date,
|
|
|
|
|
open_price, close_price, high_price, low_price, volume, turnover,
|
|
|
|
|
total_market_cap, free_circulation_cap, price_change_rate, amplitude,
|
|
|
|
|
turnover_rate, equal_weight_avg_change_rate, pe_ttm, pe_ttm_median,
|
|
|
|
|
total_market_cap, free_circulation_cap, price_change_rate, pe_ttm, pe_ttm_median,
|
|
|
|
|
up_count, down_count, limit_up_count, limit_down_count, no_change_count,
|
|
|
|
|
suspend_count, new_high_flag, new_low_flag, create_time)
|
|
|
|
|
values
|
|
|
|
|
<foreach collection="list" item="item" separator=",">
|
|
|
|
|
(#{item.industryIndexCode}, #{item.industryIndexName}, #{item.componentCount}, #{item.tradeDate},
|
|
|
|
|
#{item.openPrice}, #{item.closePrice}, #{item.highPrice}, #{item.lowPrice}, #{item.volume}, #{item.turnover},
|
|
|
|
|
#{item.totalMarketCap}, #{item.freeCirculationCap}, #{item.priceChangeRate}, #{item.amplitude},
|
|
|
|
|
#{item.turnoverRate}, #{item.equalWeightAvgChangeRate}, #{item.peTtm}, #{item.peTtmMedian},
|
|
|
|
|
#{item.totalMarketCap}, #{item.freeCirculationCap}, #{item.priceChangeRate}, #{item.peTtm}, #{item.peTtmMedian},
|
|
|
|
|
#{item.upCount}, #{item.downCount}, #{item.limitUpCount}, #{item.limitDownCount}, #{item.noChangeCount},
|
|
|
|
|
#{item.suspendCount}, #{item.newHighFlag}, #{item.newLowFlag}, NOW())
|
|
|
|
|
</foreach>
|
|
|
|
|
@ -227,9 +214,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
total_market_cap = VALUES(total_market_cap),
|
|
|
|
|
free_circulation_cap = VALUES(free_circulation_cap),
|
|
|
|
|
price_change_rate = VALUES(price_change_rate),
|
|
|
|
|
amplitude = VALUES(amplitude),
|
|
|
|
|
turnover_rate = VALUES(turnover_rate),
|
|
|
|
|
equal_weight_avg_change_rate = VALUES(equal_weight_avg_change_rate),
|
|
|
|
|
pe_ttm = VALUES(pe_ttm),
|
|
|
|
|
pe_ttm_median = VALUES(pe_ttm_median),
|
|
|
|
|
up_count = VALUES(up_count),
|
|
|
|
|
|