@@ -131,8 +131,10 @@ public interface MaterialManagementMapper {
publicbooleanupdatePlasticFilmState(longid);
@Select("<script>"+
"select * from (select name,save_date,CARD_BODY_TYPE,sum(count1) count1 ,sum(count2) count2,rownum rn\n"+
"from (select name,CARD_TYPE,CARD_BODY_TYPE,to_Char(SAVE_DATE,'yyyyMMdd') save_date, decode(card_type,2,0,total_count) count1 ,decode(card_type,1,0,total_count) count2 from CARD_BODY where (to_char(save_date,'yyyyMMdd') BETWEEN #{beginDate} and #{endDate}) and state =1 "+
"select * from (SELECT ROWNUM rn,a.* FROM(select name,save_date,CARD_BODY_TYPE,sum(count1) count1 ,sum(count2) count2 from (\n"+
"select * from (select name,save_date,CARD_BODY_TYPE,sum(count1) count1 ,sum(count2) count2,rownum rn\n"+
"from (select name,CARD_TYPE,CARD_BODY_TYPE,to_Char(SAVE_DATE,'yyyyMMdd') save_date, decode(card_type,2,0,total_count) count1 ,decode(card_type,1,0,total_count) count2 from CARD_BODY where (to_char(save_date,'yyyyMMdd') BETWEEN #{beginDate} and #{endDate}) and state =1 "+
"SELECT ROWNUM rn,a.* FROM(select name,save_date,CARD_BODY_TYPE,sum(count1) count1 ,sum(count2) count2 from ( select name,CARD_TYPE,CARD_BODY_TYPE,to_Char(SAVE_DATE,'yyyyMMdd') save_date, decode(card_type,2,0,total_count) count1 ,decode(card_type,1,0,total_count) count2 from CARD_BODY where (to_char(save_date,'yyyyMMdd') BETWEEN #{beginDate} and #{endDate}) and state =1 "+
"<if test='name != null '>"+
" and name =#{name} "+
"</if>"+
...
...
@@ -159,8 +160,7 @@ public interface MaterialManagementMapper {
"<if test='cardBodyType != 0 '>"+
" and card_Body_Type =#{cardBodyType} "+
"</if>"+
"ORDER BY save_date) \n"+
" group by name, save_date,CARD_BODY_TYPE,rownum ORDER BY save_date,rownum) "+
"ORDER BY save_date) group by name, save_date, CARD_BODY_TYPE order by SAVE_DATE) a "+
"select * from (select name,save_date,sum(count1) count1 ,sum(count2) count2,rownum rn\n"+
"from (select name,PLASTIC_FILM_TYPE,to_Char(SAVE_DATE,'yyyyMMdd') save_date, decode(PLASTIC_FILM_TYPE,2,0,total_count) count1 ,decode(PLASTIC_FILM_TYPE,1,0,total_count) count2 from PLASTIC_FILM where (to_char(save_date,'yyyyMMdd') BETWEEN #{beginDate} and #{endDate}) and state =1 "+
"select * from (select name,save_date,sum(count1) count1 ,sum(count2) count2,rownum rn\n"+
"from (select name,PLASTIC_FILM_TYPE,to_Char(SAVE_DATE,'yyyyMMdd') save_date, decode(PLASTIC_FILM_TYPE,2,0,total_count) count1 ,decode(PLASTIC_FILM_TYPE,1,0,total_count) count2 from PLASTIC_FILM where (to_char(save_date,'yyyyMMdd') BETWEEN #{beginDate} and #{endDate}) and state =1 "+
"SELECT ROWNUM rn,a.* FROM(\n"+
" select name,save_date,sum(count1) count1 ,sum(count2) count2 from ( \n"+