StringBufferhql=newStringBuffer("select organize_Code as organizeCode,part_No as partNo, date_format(plan_start_time, '%Y-%m-%d' ) as planStartTime, product_Version as productVersion, " +
" sum( CASE WHEN work_Order_Status = 40 THEN complete_Qty ELSE qty END ) AS qty " +
" from Mes_Work_Order where is_Deleted=:isDeleted and is_Valid = :isValid and organize_Code = :organizeCode " +
" and work_order_type = 20 and order_flag !='P' and part_no in (:partNoList) "+
" and work_Order_Status not in(:statusList) group by organize_code,part_No, date_format(plan_start_time, '%Y-%m-%d' ), product_Version ");
StringBufferhql=newStringBuffer("select organize_code as organizeCode,part_no as partNo, date_format(plan_start_time, '%Y-%m-%d' ) as planStartTime, product_version as productVersion, " +
" sum(case when work_order_status = 40 then complete_qty else qty end ) as qty " +
" from mes_work_order where is_deleted=:isDeleted and is_valid = :isValid and organize_code = :organizeCode " +
" and work_order_type = 20 and order_flag !='P' and work_order_status != 10 and plan_start_time >= :today" +
" group by organize_code,part_no, date_format(plan_start_time, '%Y-%m-%d' ), product_version ");