( filling_record_id IS NOT NULL ) + ( filling_before_id IS NOT NULL ) + ( filling_check_id IS NOT NULL ) + ( filling_examine_id IS NOT NULL ) + ( filling_startTime IS NOT NULL ) + ( filling_endTime IS NOT NULL ) + ( filling_user IS NOT NULL ) + ( inspector_name IS NOT NULL ) + ( filling_quantity IS NOT NULL ) + ( temperature IS NOT NULL ) + ( abnormal IS NOT NULL )
( filling_record_id IS NOT NULL ) + ( filling_before_id IS NOT NULL ) + ( filling_check_id IS NOT NULL ) + ( filling_examine_id IS NOT NULL ) + ( filling_startTime IS NOT NULL ) + ( filling_endTime IS NOT NULL ) + ( filling_user IS NOT NULL ) + ( inspector_name IS NOT NULL ) + ( filling_quantity IS NOT NULL ) + ( temperature IS NOT NULL ) + ( abnormal IS NOT NULL )
) / 11 AS DECIMAL ( 10, 2 )) integrity
) / 11 AS DECIMAL ( 10, 2 )) integrity
FROM tm_cylinder_filling_record cfr where sync_state !=3 and filling_record_id is not null
FROM tm_cylinder_filling_record cfr where sync_state !=3 and filling_record_id is not null
ORDER BY cfr.sync_date
LIMIT 5000
LIMIT 1000
</select>
</select>
<insertid="batchInsertOrUpdate">
<insertid="batchInsertOrUpdate">
INSERT INTO tz_cylinder_filling_record_2210 (sequence_nbr,
INSERT INTO tz_cylinder_filling_record (sequence_nbr,
filling_record_id,
filling_record_id,
filling_starttime,
filling_starttime,
filling_endtime,
filling_endtime,
...
@@ -318,14 +313,14 @@
...
@@ -318,14 +313,14 @@
<updateid="updateSyncState">
<updateid="updateSyncState">
update tm_cylinder_filling_record set sync_state = 3
update tm_cylinder_filling_record set sync_state = 3
concat(b.app_id, b.sequence_code) AS appIdAndSequenceCode,
concat(b.app_id, b.sequence_code) AS appIdAndSequenceCode,
b.filling_unit_name AS fillingUnitName,
tcn.unit_name AS fillingUnitName,
af.inspector AS inspector,
af.inspector AS inspector,
af.inspection_date AS inspectionDateAfter,
af.inspection_date AS inspectionDateAfter,
af.check_results AS checkResult
af.check_results AS checkResult
...
@@ -180,6 +180,7 @@
...
@@ -180,6 +180,7 @@
AND date_format ( b.inspection_date, '%Y-%m-%d' ) = date_format ( r.filling_startTime, '%Y-%m-%d' ) and b.sequence_code is not null AND b.app_id is not null
AND date_format ( b.inspection_date, '%Y-%m-%d' ) = date_format ( r.filling_startTime, '%Y-%m-%d' ) and b.sequence_code is not null AND b.app_id is not null
LEFT JOIN tz_cylinder_filling_check af ON af.filling_check_id = r.filling_check_id
LEFT JOIN tz_cylinder_filling_check af ON af.filling_check_id = r.filling_check_id
LEFT JOIN idx_biz_jg_other_info ibjoi ON bjsc.code96333 = ibjoi."CODE96333"
LEFT JOIN idx_biz_jg_supervision_info ibjsi ON ibjsi.record = ibjoi.record
WHERE
WHERE
"CODE96333" IN ( SELECT code96333 FROM "biz_jg_supervisory_code" WHERE code96333 LIKE'31%' AND supervisory_code LIKE'D%' AND (status = '1' or status = '2') )
ibjsi."ORG_BRANCH_CODE" LIKE'50*18667%'
AND "CLAIM_STATUS" = '已认领';
AND ( bjsc.code96333 LIKE'31%' OR bjsc.code96333 LIKE'33%' )