|
|
|
|
@ -107,17 +107,17 @@
|
|
|
|
|
ds.sort30 as sort30,ds.sort30_change as sort30Change,ds.trend30_value as trend30Value,ds.trend30_value_change as trend30ValueChange
|
|
|
|
|
from dong_cai_secondary_industry d
|
|
|
|
|
left join dong_cai_secondary_industry_statistics ds on (d.security_name = ds.security_name)
|
|
|
|
|
where d.business_date = #{firstDate} and ds.business_date = #{firstDate} and ds.sort > 0
|
|
|
|
|
where d.business_date = #{firstDate} and ds.business_date = #{firstDate} and ds.sort10 > 0
|
|
|
|
|
<choose>
|
|
|
|
|
<when test="sortSort != null and sortSort.trim() != '' and sortChangeSort != null and sortChangeSort.trim() != ''">
|
|
|
|
|
order by sort ${sortSort},sortChange ${sortChangeSort}
|
|
|
|
|
order by (sort10+0) ${sortSort},(sort10Change+0) ${sortChangeSort}
|
|
|
|
|
</when>
|
|
|
|
|
<otherwise>
|
|
|
|
|
<if test="sortSort != null and sortSort.trim() != '' ">
|
|
|
|
|
order by sort ${sortSort}
|
|
|
|
|
order by (sort10+0) ${sortSort}
|
|
|
|
|
</if>
|
|
|
|
|
<if test="sortChangeSort != null and sortChangeSort.trim() != ''">
|
|
|
|
|
order by sortChange ${sortChangeSort}
|
|
|
|
|
order by (sort10Change+0) ${sortChangeSort}
|
|
|
|
|
</if>
|
|
|
|
|
</otherwise>
|
|
|
|
|
</choose>
|
|
|
|
|
|