| | |
| | | |
| | | <resultMap id="temperingGlassCount" type="com.mes.bigstorage.entity.dto.TemperingGlassCountDTO"> |
| | | <result column="engineer_id" property="engineerId"/> |
| | | <result column="engineer_name" property="engineerName"/> |
| | | <result column="tempering_layout_id" property="temperingLayoutId"/> |
| | | <result column="films_id" property="filmsId"/> |
| | | <result column="thickness" property="thickness"/> |
| | |
| | | |
| | | <select id="selectTemperingGlassCount" resultMap="temperingGlassCount"> |
| | | with glass_info_temp as ( |
| | | select engineer_id, tempering_layout_id, count(*) as total_count |
| | | from glass_info |
| | | group by engineer_id, tempering_layout_id |
| | | select t.engineer_id,t1.engineer_name, t.tempering_layout_id, count(*) as total_count |
| | | from glass_info t inner join engineering t1 on t.engineer_id=t1.engineer_id |
| | | group by t.engineer_id, t.tempering_layout_id |
| | | ), |
| | | big_details_temp as ( |
| | | select engineer_id, tempering_layout_id, count(*) as real_count, films_id, thickness |
| | |
| | | ), |
| | | result as ( |
| | | select t.engineer_id, |
| | | t1.engineer_name, |
| | | t.tempering_layout_id, |
| | | t.films_id, |
| | | t.thickness, |