Merge pull request 'feat/infer_dev_260211' (#135) from feat/infer_dev_260211 into develop
Reviewed-on: #135
This commit was merged in pull request #135.
This commit is contained in:
@@ -24,7 +24,6 @@ public class InferenceResultRepositoryImpl implements InferenceResultRepositoryC
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Long upsertGroupsFromMapSheetAnal(Long id) {
|
public Long upsertGroupsFromMapSheetAnal(Long id) {
|
||||||
// id = learn 테이블 id
|
|
||||||
String sql =
|
String sql =
|
||||||
"""
|
"""
|
||||||
INSERT INTO tb_map_sheet_anal_inference (
|
INSERT INTO tb_map_sheet_anal_inference (
|
||||||
@@ -54,12 +53,12 @@ public class InferenceResultRepositoryImpl implements InferenceResultRepositoryC
|
|||||||
:pendingStateId
|
:pendingStateId
|
||||||
FROM tb_map_sheet_learn r
|
FROM tb_map_sheet_learn r
|
||||||
WHERE r.id = :id
|
WHERE r.id = :id
|
||||||
ON CONFLICT (learn_id, compare_yyyy, target_yyyy)
|
ON CONFLICT (stage, compare_yyyy, target_yyyy)
|
||||||
DO UPDATE SET
|
DO UPDATE SET
|
||||||
detecting_cnt = EXCLUDED.detecting_cnt,
|
detecting_cnt = EXCLUDED.detecting_cnt,
|
||||||
anal_title = EXCLUDED.anal_title,
|
anal_title = EXCLUDED.anal_title,
|
||||||
stage = EXCLUDED.stage,
|
updated_dttm = now(),
|
||||||
updated_dttm = now()
|
learn_id = EXCLUDED.learn_id
|
||||||
RETURNING anal_uid
|
RETURNING anal_uid
|
||||||
""";
|
""";
|
||||||
|
|
||||||
@@ -118,8 +117,9 @@ public class InferenceResultRepositoryImpl implements InferenceResultRepositoryC
|
|||||||
msl.target_yyyy,
|
msl.target_yyyy,
|
||||||
r.map_id,
|
r.map_id,
|
||||||
msl.stage
|
msl.stage
|
||||||
ON CONFLICT (anal_uid, compare_yyyy, target_yyyy, map_sheet_num)
|
ON CONFLICT (stage, compare_yyyy, target_yyyy, map_sheet_num)
|
||||||
DO UPDATE SET
|
DO UPDATE SET
|
||||||
|
anal_uid = EXCLUDED.anal_uid,
|
||||||
ref_map_sheet_num = EXCLUDED.ref_map_sheet_num,
|
ref_map_sheet_num = EXCLUDED.ref_map_sheet_num,
|
||||||
updated_dttm = now()
|
updated_dttm = now()
|
||||||
""";
|
""";
|
||||||
@@ -212,11 +212,11 @@ public class InferenceResultRepositoryImpl implements InferenceResultRepositoryC
|
|||||||
AND r.map_id ~ '^[0-9]+$'
|
AND r.map_id ~ '^[0-9]+$'
|
||||||
AND r.map_id::bigint = msadi.map_sheet_num
|
AND r.map_id::bigint = msadi.map_sheet_num
|
||||||
WHERE msl.anal_uid = :analUid
|
WHERE msl.anal_uid = :analUid
|
||||||
|
AND r.after_c is not null
|
||||||
|
AND r.after_p is not null
|
||||||
AND r.probability is not null
|
AND r.probability is not null
|
||||||
AND r.before_c is not null
|
AND r.before_c is not null
|
||||||
AND r.before_p is not null
|
AND r.before_p is not null
|
||||||
AND r.after_c is not null
|
|
||||||
AND r.after_p is not null
|
|
||||||
ORDER BY r.uid, r.created_date DESC NULLS LAST
|
ORDER BY r.uid, r.created_date DESC NULLS LAST
|
||||||
) x
|
) x
|
||||||
ON CONFLICT (result_uid)
|
ON CONFLICT (result_uid)
|
||||||
|
|||||||
Reference in New Issue
Block a user