diff --git a/mappings/info_recruits/citizen_tables/child/branching_child_delta.hpl b/mappings/info_recruits/citizen_tables/child/branching_child_delta.hpl
new file mode 100644
index 0000000..382688b
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/branching_child_delta.hpl
@@ -0,0 +1,142 @@
+
+
+
+ branching_child_delta
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/09 09:54:43.724
+ -
+ 2025/06/09 09:54:43.724
+
+
+
+
+
+ Set variables 2
+ Write to log 2
+ N
+
+
+ Table input
+ Set variables 2
+ Y
+
+
+
+ Set variables 2
+ SetVariable
+
+ Y
+
+ 1
+
+ none
+
+
+
+
+ pipeline
+ PIPE
+ PARENT_WORKFLOW
+
+
+ status
+ STATUS
+ PARENT_WORKFLOW
+
+
+ Y
+
+
+ 1056
+ 256
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ SELECT
+ COALESCE(job_name, 'job_child_delta') AS PIPELINE,
+ COALESCE(status, 'ERROR') AS STATUS,
+ current_timestamp::timestamp as record_created
+FROM (
+ select
+ CASE
+ WHEN status = 'PROCESSING' THEN 'ERROR'
+ ELSE status
+ END AS status,
+ job_name
+ from public.etl_checkpoints
+ where job_name = 'job_child_delta'
+
+ UNION ALL
+
+ SELECT NULL, NULL
+ WHERE NOT EXISTS (
+ SELECT 1
+ FROM public.etl_checkpoints
+ WHERE job_name = 'job_child_delta'
+ )
+) t
+ N
+
+
+ 816
+ 256
+
+
+
+ Write to log 2
+ WriteToLog
+
+ Y
+
+ 1
+
+ none
+
+
+ Y
+
+
+ pipeline
+
+
+ status
+
+
+ N
+ 0
+ Basic
+ ${PIPE}
+${STATUS}
+
+
+ 1280
+ 256
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow1_error.hpl b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow1_error.hpl
new file mode 100644
index 0000000..782c038
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow1_error.hpl
@@ -0,0 +1,101 @@
+
+
+
+ change_status_delta_child_flow1_error
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/16 12:20:06.191
+ -
+ 2025/06/16 12:20:06.191
+
+
+
+
+
+ Table input
+ Insert / update
+ Y
+
+
+
+ Insert / update
+ InsertUpdate
+
+ Y
+
+ 1
+
+ none
+
+
+ 100
+ ervu-dashboard
+
+
+ =
+ job_name
+ job_name
+
+ public
+
+
+ job_name
+ job_name
+ N
+
+
+ record_created
+ record_created
+ Y
+
+
+ status
+ status
+ Y
+
+
+ N
+
+
+ 1152
+ 304
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ SELECT
+ 'delta_child_flow1' as job_name,
+ 'ERROR' as status,
+ current_timestamp as record_created
+ N
+
+
+ 784
+ 304
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_success.hpl b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow1_success.hpl
similarity index 92%
rename from mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_success.hpl
rename to mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow1_success.hpl
index 081660e..7a7dc06 100644
--- a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_success.hpl
+++ b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow1_success.hpl
@@ -1,7 +1,7 @@
- change_status_delta_child_success
+ change_status_delta_child_flow1_success
Y
@@ -85,14 +85,7 @@
N
0
SELECT
- 'delta_child' as job_name,
- 'SUCCESS' as status,
- current_timestamp as record_created
-
-union all
-
- SELECT
- 'job_child' as job_name,
+ 'delta_child_flow1' as job_name,
'SUCCESS' as status,
current_timestamp as record_created
diff --git a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow2_error.hpl b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow2_error.hpl
new file mode 100644
index 0000000..a420549
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow2_error.hpl
@@ -0,0 +1,101 @@
+
+
+
+ change_status_delta_child_flow2_error
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/16 12:20:06.191
+ -
+ 2025/06/16 12:20:06.191
+
+
+
+
+
+ Table input
+ Insert / update
+ Y
+
+
+
+ Insert / update
+ InsertUpdate
+
+ Y
+
+ 1
+
+ none
+
+
+ 100
+ ervu-dashboard
+
+
+ =
+ job_name
+ job_name
+
+ public
+
+
+ job_name
+ job_name
+ N
+
+
+ record_created
+ record_created
+ Y
+
+
+ status
+ status
+ Y
+
+
+ N
+
+
+ 1152
+ 304
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ SELECT
+ 'delta_child_flow2' as job_name,
+ 'ERROR' as status,
+ current_timestamp as record_created
+ N
+
+
+ 784
+ 304
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_error.hpl b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow2_success.hpl
similarity index 91%
rename from mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_error.hpl
rename to mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow2_success.hpl
index cc3d677..0c50fd3 100644
--- a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_error.hpl
+++ b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow2_success.hpl
@@ -1,7 +1,7 @@
- change_status_delta_child_error
+ change_status_delta_child_flow2_success
Y
@@ -85,15 +85,8 @@
N
0
SELECT
- 'delta_child' as job_name,
- 'ERROR' as status,
- current_timestamp as record_created
-
-union all
-
- SELECT
- 'job_child' as job_name,
- 'ERROR' as status,
+ 'delta_child_flow2' as job_name,
+ 'SUCCESS' as status,
current_timestamp as record_created
diff --git a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow3_error.hpl b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow3_error.hpl
new file mode 100644
index 0000000..16a7007
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow3_error.hpl
@@ -0,0 +1,101 @@
+
+
+
+ change_status_delta_child_flow3_error
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/16 12:20:06.191
+ -
+ 2025/06/16 12:20:06.191
+
+
+
+
+
+ Table input
+ Insert / update
+ Y
+
+
+
+ Insert / update
+ InsertUpdate
+
+ Y
+
+ 1
+
+ none
+
+
+ 100
+ ervu-dashboard
+
+
+ =
+ job_name
+ job_name
+
+ public
+
+
+ job_name
+ job_name
+ N
+
+
+ record_created
+ record_created
+ Y
+
+
+ status
+ status
+ Y
+
+
+ N
+
+
+ 1152
+ 304
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ SELECT
+ 'delta_child_flow3' as job_name,
+ 'ERROR' as status,
+ current_timestamp as record_created
+ N
+
+
+ 784
+ 304
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow3_success.hpl b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow3_success.hpl
new file mode 100644
index 0000000..96e5db8
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow3_success.hpl
@@ -0,0 +1,103 @@
+
+
+
+ change_status_delta_child_flow3_success
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/16 12:20:06.191
+ -
+ 2025/06/16 12:20:06.191
+
+
+
+
+
+ Table input
+ Insert / update
+ Y
+
+
+
+ Insert / update
+ InsertUpdate
+
+ Y
+
+ 1
+
+ none
+
+
+ 100
+ ervu-dashboard
+
+
+ =
+ job_name
+ job_name
+
+ public
+
+
+ job_name
+ job_name
+ N
+
+
+ record_created
+ record_created
+ Y
+
+
+ status
+ status
+ Y
+
+
+ N
+
+
+ 1152
+ 304
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ SELECT
+ 'delta_child_flow3' as job_name,
+ 'SUCCESS' as status,
+ current_timestamp as record_created
+
+
+ N
+
+
+ 784
+ 304
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow4_error.hpl b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow4_error.hpl
new file mode 100644
index 0000000..c39e38f
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow4_error.hpl
@@ -0,0 +1,101 @@
+
+
+
+ change_status_delta_child_flow4_error
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/16 12:20:06.191
+ -
+ 2025/06/16 12:20:06.191
+
+
+
+
+
+ Table input
+ Insert / update
+ Y
+
+
+
+ Insert / update
+ InsertUpdate
+
+ Y
+
+ 1
+
+ none
+
+
+ 100
+ ervu-dashboard
+
+
+ =
+ job_name
+ job_name
+
+ public
+
+
+ job_name
+ job_name
+ N
+
+
+ record_created
+ record_created
+ Y
+
+
+ status
+ status
+ Y
+
+
+ N
+
+
+ 1152
+ 304
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ SELECT
+ 'delta_child_flow4' as job_name,
+ 'ERROR' as status,
+ current_timestamp as record_created
+ N
+
+
+ 784
+ 304
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow4_success.hpl b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow4_success.hpl
new file mode 100644
index 0000000..381c4fc
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow4_success.hpl
@@ -0,0 +1,103 @@
+
+
+
+ change_status_delta_child_flow4_success
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/16 12:20:06.191
+ -
+ 2025/06/16 12:20:06.191
+
+
+
+
+
+ Table input
+ Insert / update
+ Y
+
+
+
+ Insert / update
+ InsertUpdate
+
+ Y
+
+ 1
+
+ none
+
+
+ 100
+ ervu-dashboard
+
+
+ =
+ job_name
+ job_name
+
+ public
+
+
+ job_name
+ job_name
+ N
+
+
+ record_created
+ record_created
+ Y
+
+
+ status
+ status
+ Y
+
+
+ N
+
+
+ 1152
+ 304
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ SELECT
+ 'delta_child_flow4' as job_name,
+ 'SUCCESS' as status,
+ current_timestamp as record_created
+
+
+ N
+
+
+ 784
+ 304
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow5_error.hpl b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow5_error.hpl
new file mode 100644
index 0000000..460b876
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow5_error.hpl
@@ -0,0 +1,101 @@
+
+
+
+ change_status_delta_child_flow5_error
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/16 12:20:06.191
+ -
+ 2025/06/16 12:20:06.191
+
+
+
+
+
+ Table input
+ Insert / update
+ Y
+
+
+
+ Insert / update
+ InsertUpdate
+
+ Y
+
+ 1
+
+ none
+
+
+ 100
+ ervu-dashboard
+
+
+ =
+ job_name
+ job_name
+
+ public
+
+
+ job_name
+ job_name
+ N
+
+
+ record_created
+ record_created
+ Y
+
+
+ status
+ status
+ Y
+
+
+ N
+
+
+ 1152
+ 304
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ SELECT
+ 'delta_child_flow5' as job_name,
+ 'ERROR' as status,
+ current_timestamp as record_created
+ N
+
+
+ 784
+ 304
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow5_success.hpl b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow5_success.hpl
new file mode 100644
index 0000000..8035bc7
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow5_success.hpl
@@ -0,0 +1,103 @@
+
+
+
+ change_status_delta_child_flow5_success
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/16 12:20:06.191
+ -
+ 2025/06/16 12:20:06.191
+
+
+
+
+
+ Table input
+ Insert / update
+ Y
+
+
+
+ Insert / update
+ InsertUpdate
+
+ Y
+
+ 1
+
+ none
+
+
+ 100
+ ervu-dashboard
+
+
+ =
+ job_name
+ job_name
+
+ public
+
+
+ job_name
+ job_name
+ N
+
+
+ record_created
+ record_created
+ Y
+
+
+ status
+ status
+ Y
+
+
+ N
+
+
+ 1152
+ 304
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ SELECT
+ 'delta_child_flow5' as job_name,
+ 'SUCCESS' as status,
+ current_timestamp as record_created
+
+
+ N
+
+
+ 784
+ 304
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_to_processing_delta.hpl b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_to_processing_delta.hpl
index 8be76b7..64b8f84 100644
--- a/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_to_processing_delta.hpl
+++ b/mappings/info_recruits/citizen_tables/child/checkpoints/change_status_to_processing_delta.hpl
@@ -88,6 +88,46 @@
'PROCESSING' AS status,
'delta_child' AS job_name,
current_timestamp AS record_created
+--FROM public.etl_checkpoints
+
+UNION ALL
+
+SELECT
+ 'PROCESSING' AS status,
+ 'child_delta_flow1' AS job_name,
+ current_timestamp AS record_created
+--FROM public.etl_checkpoints
+
+UNION ALL
+
+SELECT
+ 'PROCESSING' AS status,
+ 'child_delta_flow2' AS job_name,
+ current_timestamp AS record_created
+--FROM public.etl_checkpoints
+
+UNION ALL
+
+SELECT
+ 'PROCESSING' AS status,
+ 'child_delta_flow3' AS job_name,
+ current_timestamp AS record_created
+--FROM public.etl_checkpoints
+
+UNION ALL
+
+SELECT
+ 'PROCESSING' AS status,
+ 'child_delta_flow4' AS job_name,
+ current_timestamp AS record_created
+--FROM public.etl_checkpoints
+
+UNION ALL
+
+SELECT
+ 'PROCESSING' AS status,
+ 'child_delta_flow5' AS job_name,
+ current_timestamp AS record_created
--FROM public.etl_checkpoints
N
diff --git a/mappings/info_recruits/citizen_tables/child/checkpoints/checkpoint_job_child_delta.hpl b/mappings/info_recruits/citizen_tables/child/checkpoints/checkpoint_job_child_delta.hpl
new file mode 100644
index 0000000..9097bd1
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/checkpoints/checkpoint_job_child_delta.hpl
@@ -0,0 +1,869 @@
+
+
+
+ checkpoint_job_child_delta
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/03 14:19:02.590
+ -
+ 2025/06/03 14:19:02.590
+
+
+
+
+
+ Filter rows
+ Abort
+ N
+
+
+ JSON input state_child_flow1.json
+ Filter rows
+ N
+
+
+ JSON input state_child_flow2.json
+ Filter rows
+ N
+
+
+ JSON input state_child_flow3.json
+ Filter rows
+ N
+
+
+ JSON input state_child_flow4.json
+ Filter rows
+ N
+
+
+ JSON input state_child_flow5.json
+ Filter rows
+ N
+
+
+ Table input
+ Insert / update
+ Y
+
+
+ Dummy (do nothing)
+ JSON input state_child_flow1.json
+ N
+
+
+ Dummy (do nothing)
+ JSON input state_child_flow2.json
+ N
+
+
+ Dummy (do nothing)
+ JSON input state_child_flow3.json
+ N
+
+
+ Dummy (do nothing)
+ JSON input state_child_flow4.json
+ N
+
+
+ Dummy (do nothing)
+ JSON input state_child_flow5.json
+ N
+
+
+
+ Abort
+ Abort
+
+ Y
+
+ 1
+
+ none
+
+
+ ABORT_WITH_ERROR
+ Y
+ 0
+
+
+ 1264
+ 592
+
+
+
+ Dummy (do nothing)
+ Dummy
+
+ Y
+
+ 1
+
+ none
+
+
+
+
+ 352
+ 592
+
+
+
+ Filter rows
+ FilterRows
+
+ Y
+
+ 1
+
+ none
+
+
+
+
+
+
+
+
+
+
+ =
+ pipeline
+ N
+ -
+
+ N
+ -1
+ constant
+ -1
+ child_flow1
+ String
+
+
+
+
+
+ =
+ status
+ N
+ AND
+
+ N
+ -1
+ constant
+ -1
+ ERROR
+ String
+
+
+
+ =
+ pipeline
+ N
+ -
+
+ N
+ -1
+ constant
+ -1
+ recruits_info_flow1
+ String
+
+
+
+
+
+
+
+ =
+ pipeline
+ N
+ -
+
+ N
+ -1
+ constant
+ -1
+ child_flow2
+ String
+
+
+
+
+
+ =
+ status
+ N
+ AND
+
+ N
+ -1
+ constant
+ -1
+ ERROR
+ String
+
+
+
+ =
+ pipeline
+ N
+ OR
+
+ N
+ -1
+ constant
+ -1
+ recruits_info_flow1
+ String
+
+
+
+
+
+
+
+ =
+ pipeline
+ N
+ -
+
+ N
+ -1
+ constant
+ -1
+ child_flow3
+ String
+
+
+
+
+
+ =
+ status
+ N
+ AND
+
+ N
+ -1
+ constant
+ -1
+ ERROR
+ String
+
+
+
+ =
+ pipeline
+ N
+ OR
+
+ N
+ -1
+ constant
+ -1
+ recruits_info_flow1
+ String
+
+
+
+
+
+
+
+ =
+ pipeline
+ N
+ -
+
+ N
+ -1
+ constant
+ -1
+ child_flow4
+ String
+
+
+
+
+
+ =
+ status
+ N
+ AND
+
+ N
+ -1
+ constant
+ -1
+ ERROR
+ String
+
+
+
+ =
+ pipeline
+ N
+ OR
+
+ N
+ -1
+ constant
+ -1
+ recruits_info_flow1
+ String
+
+
+
+
+
+
+
+ =
+ pipeline
+ N
+ -
+
+ N
+ -1
+ constant
+ -1
+ child_flow5
+ String
+
+
+
+
+
+ =
+ status
+ N
+ AND
+
+ N
+ -1
+ constant
+ -1
+ ERROR
+ String
+
+
+
+ =
+ pipeline
+ N
+ OR
+
+ N
+ -1
+ constant
+ -1
+ recruits_info_flow1
+ String
+
+
+
+ =
+ pipeline
+ N
+ -
+
+ N
+ -1
+ constant
+ -1
+ recruits_info_flow1
+ String
+
+
+
+ Abort
+
+
+ 944
+ 592
+
+
+
+ Insert / update
+ InsertUpdate
+
+ Y
+
+ 1
+
+ none
+
+
+ 100
+ ervu-dashboard
+
+
+ =
+ job_name
+ job_name
+
+ public
+
+
+ job_name
+ job_name
+ N
+
+
+ record_created
+ record_created
+ Y
+
+
+ status
+ status
+ Y
+
+
+ N
+
+
+ 1264
+ 208
+
+
+
+ JSON input state_child_flow1.json
+ JsonInput
+
+ Y
+
+ 1
+
+ none
+
+
+ N
+
+ N
+ N
+ N
+ N
+ N
+ Y
+ Y
+ Y
+
+
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow1.json
+
+
+ N
+ N
+
+
+
+ pipeline
+ $.pipeline
+ String
+
+
+
+
+ -1
+ -1
+ none
+ N
+
+
+ status
+ $.status
+ String
+
+
+
+
+ -1
+ -1
+ none
+ N
+
+
+ 0
+ N
+ N
+
+
+
+
+
+
+
+
+
+
+
+ 640
+ 432
+
+
+
+ JSON input state_child_flow2.json
+ JsonInput
+
+ Y
+
+ 1
+
+ none
+
+
+ N
+
+ N
+ N
+ N
+ N
+ N
+ Y
+ Y
+ Y
+
+
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow2.json
+
+
+ N
+ N
+
+
+
+ pipeline
+ $.pipeline
+ String
+
+
+
+
+ -1
+ -1
+ none
+ N
+
+
+ status
+ $.status
+ String
+
+
+
+
+ -1
+ -1
+ none
+ N
+
+
+ 0
+ N
+ N
+
+
+
+
+
+
+
+
+
+
+
+ 640
+ 512
+
+
+
+ JSON input state_child_flow3.json
+ JsonInput
+
+ Y
+
+ 1
+
+ none
+
+
+ N
+
+ N
+ N
+ N
+ N
+ N
+ Y
+ Y
+ Y
+
+
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow3.json
+
+
+ N
+ N
+
+
+
+ pipeline
+ $.pipeline
+ String
+
+
+
+
+ -1
+ -1
+ none
+ N
+
+
+ status
+ $.status
+ String
+
+
+
+
+ -1
+ -1
+ none
+ N
+
+
+ 0
+ N
+ N
+
+
+
+
+
+
+
+
+
+
+
+ 640
+ 592
+
+
+
+ JSON input state_child_flow4.json
+ JsonInput
+
+ Y
+
+ 1
+
+ none
+
+
+ N
+
+ N
+ N
+ N
+ N
+ N
+ Y
+ Y
+ Y
+
+
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow4.json
+
+
+ N
+ N
+
+
+
+ pipeline
+ $.pipeline
+ String
+
+
+
+
+ -1
+ -1
+ none
+ N
+
+
+ status
+ $.status
+ String
+
+
+
+
+ -1
+ -1
+ none
+ N
+
+
+ 0
+ N
+ N
+
+
+
+
+
+
+
+
+
+
+
+ 640
+ 672
+
+
+
+ JSON input state_child_flow5.json
+ JsonInput
+
+ Y
+
+ 1
+
+ none
+
+
+ N
+
+ N
+ N
+ N
+ N
+ N
+ Y
+ Y
+ Y
+
+
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow5.json
+
+
+ N
+ N
+
+
+
+ pipeline
+ $.pipeline
+ String
+
+
+
+
+ -1
+ -1
+ none
+ N
+
+
+ status
+ $.status
+ String
+
+
+
+
+ -1
+ -1
+ none
+ N
+
+
+ 0
+ N
+ N
+
+
+
+
+
+
+
+
+
+
+
+ 640
+ 752
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ WITH status_check AS (
+ SELECT
+ bool_or(status = 'ERROR' AND job_name IN (
+ 'delta_child_flow1',
+ 'delta_child_flow2',
+ 'delta_child_flow3',
+ 'delta_child_flow4',
+ 'delta_child_flow5'
+ )) AS has_error,
+ count(*) FILTER (
+ WHERE status = 'SUCCESS' AND job_name IN (
+ 'delta_child_flow1',
+ 'delta_child_flow2',
+ 'delta_child_flow3',
+ 'delta_child_flow4',
+ 'delta_child_flow5'
+ )
+ ) = 5 AS all_success
+ FROM public.etl_checkpoints
+)
+SELECT
+ 'job_child_delta' as job_name,
+ CASE
+ WHEN has_error THEN 'ERROR'
+ WHEN all_success THEN 'SUCCESS'
+ ELSE 'ERROR'
+ END AS status,
+ current_timestamp AS record_created
+FROM status_check;
+ N
+
+
+ 896
+ 208
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/job_child.hwf b/mappings/info_recruits/citizen_tables/child/job_child.hwf
index d7842b2..9dd20b8 100644
--- a/mappings/info_recruits/citizen_tables/child/job_child.hwf
+++ b/mappings/info_recruits/citizen_tables/child/job_child.hwf
@@ -304,8 +304,8 @@
variable
STATUS
N
- 1840
- 1792
+ 1696
+ 1712
@@ -514,7 +514,7 @@
- delta_child.hpl
+ delta_child_flow1.hpl
PIPELINE
@@ -523,44 +523,28 @@
N
N
N
- N
- ${PROJECT_HOME}/info_recruits/citizen_tables/child/delta_child.hpl
+ Y
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/delta_child_flow1.hpl
Basic
M_R_UP_DATE
${M_R_UP_DATE}
+
+ ID_F1
+ IDM_FLOW1
+
Y
- N
+ Y
local
N
N
Y
N
- 2640
- 1792
-
-
-
- Success delta_citizen
-
- SUCCESS
-
- N
- 3216
- 1792
-
-
-
- error delta_citizen
-
- SUCCESS
-
- N
- 3216
- 1872
+ 2672
+ 1776
@@ -629,8 +613,8 @@
N
Y
N
- 1136
- 400
+ 2368
+ 576
@@ -920,7 +904,7 @@
- Success new citizen 2
+ Success child after error
SUCCESS
@@ -1237,8 +1221,8 @@
N
Y
N
- 2112
- 1280
+ 2416
+ 1472
@@ -1263,12 +1247,12 @@
N
Y
N
- 2096
- 1792
+ 2320
+ 2304
- change_status_delta_child_success.hpl
+ change_status_delta_child_flow1_success.hpl
PIPELINE
@@ -1278,7 +1262,7 @@
N
N
N
- ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_success.hpl
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow1_success.hpl
Basic
Y
@@ -1290,11 +1274,11 @@
Y
N
2992
- 1792
+ 1776
- change_status_delta_child_error.hpl
+ change_status_delta_child_flow1_error.hpl
PIPELINE
@@ -1304,7 +1288,7 @@
N
N
N
- ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_error.hpl
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow1_error.hpl
Basic
Y
@@ -1316,7 +1300,478 @@
Y
N
2992
- 1872
+ 1856
+
+
+
+ recruitment_rows_five_flow_child.hpl 2
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ N
+ ${PROJECT_HOME}/info_recruits/supportive_jobs/recruitment_rows_five_flow_child.hpl
+ Basic
+
+ Y
+
+ N
+ local
+ N
+ N
+ Y
+ Y
+ 2416
+ 2096
+
+
+
+ Abort workflow 2 2
+
+ ABORT
+
+ N
+ N
+ 2256
+ 2208
+
+
+
+ Simple delta_child WHERE ERROR
+
+ SIMPLE_EVAL
+
+ ERROR
+ string
+ true
+ equal
+ equal
+ N
+ variable
+ STATUS
+ N
+ 2048
+ 2096
+
+
+
+ delta_child success
+
+ SUCCESS
+
+ N
+ 2144
+ 1904
+
+
+
+ branching_child_delta.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ N
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/branching_child_delta.hpl
+ Basic
+
+ Y
+
+ N
+ local
+ N
+ N
+ Y
+ N
+ 1792
+ 2096
+
+
+
+ checkpoint_job_child_delta.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ N
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/checkpoint_job_child_delta.hpl
+ Basic
+
+ Y
+
+ N
+ local
+ N
+ N
+ Y
+ N
+ 3456
+ 2096
+
+
+
+ child_delta success
+
+ SUCCESS
+
+ N
+ 3712
+ 2096
+
+
+
+ delta_child_flow2.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ Y
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/delta_child_flow2.hpl
+ Basic
+
+
+ M_R_UP_DATE
+ ${M_R_UP_DATE}
+
+
+ ID_F2
+ IDM_FLOW2
+
+ Y
+
+ Y
+ local
+ N
+ N
+ Y
+ N
+ 2672
+ 1936
+
+
+
+ change_status_delta_child_flow2_success.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ N
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow2_success.hpl
+ Basic
+
+ Y
+
+ N
+ local
+ N
+ N
+ Y
+ N
+ 2992
+ 1936
+
+
+
+ change_status_delta_child_flow2_error.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ N
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow2_error.hpl
+ Basic
+
+ Y
+
+ N
+ local
+ N
+ N
+ Y
+ N
+ 2992
+ 2016
+
+
+
+ delta_child_flow3.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ Y
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/delta_child_flow3.hpl
+ Basic
+
+
+ M_R_UP_DATE
+ ${M_R_UP_DATE}
+
+
+ ID_F3
+ IDM_FLOW3
+
+ Y
+
+ Y
+ local
+ N
+ N
+ Y
+ N
+ 2672
+ 2096
+
+
+
+ change_status_delta_child_flow3_success.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ N
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow3_success.hpl
+ Basic
+
+ Y
+
+ N
+ local
+ N
+ N
+ Y
+ N
+ 2992
+ 2096
+
+
+
+ change_status_delta_child_flow3_error.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ N
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow3_error.hpl
+ Basic
+
+ Y
+
+ N
+ local
+ N
+ N
+ Y
+ N
+ 2992
+ 2176
+
+
+
+ delta_child_flow4.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ Y
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/delta_child_flow4.hpl
+ Basic
+
+
+ M_R_UP_DATE
+ ${M_R_UP_DATE}
+
+
+ ID_F4
+ IDM_FLOW4
+
+ Y
+
+ Y
+ local
+ N
+ N
+ Y
+ N
+ 2672
+ 2256
+
+
+
+ change_status_delta_child_flow4_success.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ N
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow4_success.hpl
+ Basic
+
+ Y
+
+ N
+ local
+ N
+ N
+ Y
+ N
+ 2992
+ 2256
+
+
+
+ change_status_delta_child_flow4_error.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ N
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow4_error.hpl
+ Basic
+
+ Y
+
+ N
+ local
+ N
+ N
+ Y
+ N
+ 2992
+ 2336
+
+
+
+ delta_child_flow5.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ Y
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/delta_child_flow5.hpl
+ Basic
+
+
+ M_R_UP_DATE
+ ${M_R_UP_DATE}
+
+
+ ID_F5
+ IDM_FLOW5
+
+ Y
+
+ Y
+ local
+ N
+ N
+ Y
+ N
+ 2672
+ 2416
+
+
+
+ change_status_delta_child_flow5_success.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ N
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow5_success.hpl
+ Basic
+
+ Y
+
+ N
+ local
+ N
+ N
+ Y
+ N
+ 2992
+ 2416
+
+
+
+ change_status_delta_child_flow5_error.hpl
+
+ PIPELINE
+
+ N
+ N
+ N
+ N
+ N
+ N
+ ${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/change_status_delta_child_flow5_error.hpl
+ Basic
+
+ Y
+
+ N
+ local
+ N
+ N
+ Y
+ N
+ 2992
+ 2496
@@ -1433,20 +1888,6 @@
Y
N
-
- Simple job_child_exists check NEW
- change_status_to_processing.hpl
- Y
- Y
- N
-
-
- change_status_to_processing.hpl
- recruitment_rows_five_flow_child.hpl
- Y
- Y
- N
-
child_flow1.hpl
change_status_child_flow1_success.hpl
@@ -1666,7 +2107,7 @@
checkpoint_job_child.hpl 2
- Success new citizen 2
+ Success child after error
Y
Y
N
@@ -1756,61 +2197,257 @@
N
- Simple child WHERE ERROR
- change_status_to_processing.hpl 2
+ delta_child_flow1.hpl
+ change_status_delta_child_flow1_success.hpl
Y
Y
N
- change_status_to_processing.hpl 2
+ delta_child_flow1.hpl
+ change_status_delta_child_flow1_error.hpl
+ Y
+ N
+ N
+
+
+ Simple job_child_exists check NEW
+ recruitment_rows_five_flow_child.hpl
+ Y
+ Y
+ N
+
+
+ recruitment_rows_five_flow_child.hpl
+ change_status_to_processing.hpl
+ Y
+ Y
+ N
+
+
+ Simple child WHERE ERROR
recruitment_rows_five_flow_if_error.hpl
Y
Y
N
- Simple child WHERE SUCCESS
+ recruitment_rows_five_flow_if_error.hpl
+ change_status_to_processing.hpl 2
+ Y
+ Y
+ N
+
+
+ recruitment_rows_five_flow_child.hpl 2
+ delta_child_flow1.hpl
+ Y
+ Y
+ N
+
+
+ recruitment_rows_five_flow_child.hpl 2
change_status_to_processing_delta.hpl
Y
Y
N
- delta_child.hpl
- change_status_delta_child_success.hpl
+ recruitment_rows_five_flow_child.hpl 2
+ Abort workflow 2 2
Y
Y
N
- change_status_delta_child_success.hpl
- Success delta_citizen
- Y
- Y
- N
-
-
- delta_child.hpl
- change_status_delta_child_error.hpl
+ Simple delta_child WHERE ERROR
+ delta_child success
Y
N
N
- change_status_delta_child_error.hpl
- error delta_citizen
+ Simple delta_child WHERE ERROR
+ recruitment_rows_five_flow_child.hpl 2
+ Y
+ Y
+ Y
+
+
+ Simple child WHERE SUCCESS
+ branching_child_delta.hpl
Y
Y
N
- change_status_to_processing_delta.hpl
- delta_child.hpl
+ branching_child_delta.hpl
+ Simple delta_child WHERE ERROR
+ Y
+ Y
+ Y
+
+
+ checkpoint_job_child_delta.hpl
+ child_delta success
Y
Y
N
+
+ change_status_delta_child_flow1_success.hpl
+ checkpoint_job_child_delta.hpl
+ Y
+ N
+ Y
+
+
+ change_status_delta_child_flow1_error.hpl
+ checkpoint_job_child_delta.hpl
+ Y
+ N
+ Y
+
+
+ delta_child_flow2.hpl
+ change_status_delta_child_flow2_success.hpl
+ Y
+ Y
+ N
+
+
+ delta_child_flow2.hpl
+ change_status_delta_child_flow2_error.hpl
+ Y
+ N
+ N
+
+
+ delta_child_flow3.hpl
+ change_status_delta_child_flow3_success.hpl
+ Y
+ Y
+ N
+
+
+ delta_child_flow3.hpl
+ change_status_delta_child_flow3_error.hpl
+ Y
+ N
+ N
+
+
+ delta_child_flow4.hpl
+ change_status_delta_child_flow4_success.hpl
+ Y
+ Y
+ N
+
+
+ delta_child_flow4.hpl
+ change_status_delta_child_flow4_error.hpl
+ Y
+ N
+ N
+
+
+ delta_child_flow5.hpl
+ change_status_delta_child_flow5_success.hpl
+ Y
+ Y
+ N
+
+
+ delta_child_flow5.hpl
+ change_status_delta_child_flow5_error.hpl
+ Y
+ N
+ N
+
+
+ recruitment_rows_five_flow_child.hpl 2
+ delta_child_flow2.hpl
+ Y
+ Y
+ N
+
+
+ recruitment_rows_five_flow_child.hpl 2
+ delta_child_flow3.hpl
+ Y
+ Y
+ N
+
+
+ recruitment_rows_five_flow_child.hpl 2
+ delta_child_flow4.hpl
+ Y
+ Y
+ N
+
+
+ recruitment_rows_five_flow_child.hpl 2
+ delta_child_flow5.hpl
+ Y
+ Y
+ N
+
+
+ change_status_delta_child_flow2_success.hpl
+ checkpoint_job_child_delta.hpl
+ Y
+ N
+ Y
+
+
+ change_status_delta_child_flow3_success.hpl
+ checkpoint_job_child_delta.hpl
+ Y
+ N
+ Y
+
+
+ change_status_delta_child_flow2_error.hpl
+ checkpoint_job_child_delta.hpl
+ Y
+ N
+ Y
+
+
+ change_status_delta_child_flow3_error.hpl
+ checkpoint_job_child_delta.hpl
+ Y
+ N
+ Y
+
+
+ change_status_delta_child_flow4_success.hpl
+ checkpoint_job_child_delta.hpl
+ Y
+ N
+ Y
+
+
+ change_status_delta_child_flow4_error.hpl
+ checkpoint_job_child_delta.hpl
+ Y
+ N
+ Y
+
+
+ change_status_delta_child_flow5_success.hpl
+ checkpoint_job_child_delta.hpl
+ Y
+ N
+ Y
+
+
+ change_status_delta_child_flow5_error.hpl
+ checkpoint_job_child_delta.hpl
+ Y
+ N
+ Y
+
diff --git a/mappings/info_recruits/citizen_tables/child/delta_child.hpl b/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow1.hpl
similarity index 94%
rename from mappings/info_recruits/citizen_tables/child/delta_child.hpl
rename to mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow1.hpl
index c367eaf..8008a21 100644
--- a/mappings/info_recruits/citizen_tables/child/delta_child.hpl
+++ b/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow1.hpl
@@ -1,7 +1,7 @@
- delta_child
+ delta_child_flow1
Y
@@ -108,8 +108,8 @@
(select jsonb_array_elements(ri.info->'svedFL'->'svedDeti'->'rebenok') ch,
ri.recruit_id
from ervu_dashboard.recruits_info ri
-join ervu_dashboard.citizen r ON r.recruit_id = ri.recruit_id --AND '${ID_F1}' != '' -- Проверка на пустую строку
- --AND COALESCE(ri.current_recruitment_id, ri.target_recruitment_id) = '${ID_F1}'
+join ervu_dashboard.citizen r ON r.recruit_id = ri.recruit_id AND '${ID_F1}' != '' -- Проверка на пустую строку
+ AND COALESCE(ri.current_recruitment_id, ri.target_recruitment_id) = '${ID_F1}'
AND '${M_R_CR_DATE}'::timestamp >= ri.created_at
AND ri.updated_at >= '${M_R_UP_DATE}'::timestamp
where jsonb_typeof(ri.info->'svedFL'->'svedDeti'->'rebenok') = 'array'
diff --git a/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow2.hpl b/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow2.hpl
new file mode 100644
index 0000000..c108637
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow2.hpl
@@ -0,0 +1,143 @@
+
+
+
+ delta_child_flow2
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/03 16:10:48.509
+ -
+ 2025/06/03 16:10:48.509
+
+
+
+
+
+ Table input
+ Insert / update
+ Y
+
+
+
+ Insert / update
+ InsertUpdate
+
+ Y
+
+ 1
+
+ none
+
+
+ 100
+ ervu-dashboard
+
+
+ =
+ recruit_id
+ recruit_id
+
+ ervu_dashboard
+
+
+ recruit_id
+ recruit_id
+ N
+
+
+ birth_az_number
+ birth_az_number
+ Y
+
+
+ birth_date
+ birth_date
+ Y
+
+
+ death_az_number
+ death_az_number
+ Y
+
+
+ death_date
+ death_date
+ Y
+
+
+ full_name
+ full_name
+ Y
+
+
+ kinship_type
+ kinship_type
+ Y
+
+
+ N
+
+
+ 1168
+ 352
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ with child as
+(select jsonb_array_elements(ri.info->'svedFL'->'svedDeti'->'rebenok') ch,
+ ri.recruit_id
+from ervu_dashboard.recruits_info ri
+join ervu_dashboard.citizen r ON r.recruit_id = ri.recruit_id AND '${ID_F2}' != '' -- Проверка на пустую строку
+ AND COALESCE(ri.current_recruitment_id, ri.target_recruitment_id) = '${ID_F2}'
+ AND '${M_R_CR_DATE}'::timestamp >= ri.created_at
+ AND ri.updated_at >= '${M_R_UP_DATE}'::timestamp
+where jsonb_typeof(ri.info->'svedFL'->'svedDeti'->'rebenok') = 'array'
+)
+select
+ r.recruit_id::uuid recruit_id,
+ ch->>'naimRodstvSvyazReb' kinship_type,
+ concat_ws(' ', ch->'svedFLBS'->'fio'->>'familiya',
+ ch->'svedFLBS'->'fio'->>'imya',
+ ch->'svedFLBS'->'fio'->>'otchestvo') full_name,
+ make_date(NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'god', '')::int,
+ NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'mesyacz','')::int,
+ NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'den','')::int) birth_date,
+ make_date(NULLIF(ch->'svedSmert'->'dataSmert'->>'god', '')::int,
+ NULLIF(ch->'svedSmert'->'dataSmert'->>'mesyacz','')::int,
+ NULLIF(ch->'svedSmert'->'dataSmert'->>'den','')::int) death_date,
+ ch->'svedSmert'->>'nomerZapis' death_az_number,
+ ch->'svedAZRozhd'->>'nomerZapis' birth_az_number
+from ervu_dashboard.citizen r
+join child on r.recruit_id = child.recruit_id
+ Y
+
+
+ 624
+ 352
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow3.hpl b/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow3.hpl
new file mode 100644
index 0000000..7908b8e
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow3.hpl
@@ -0,0 +1,143 @@
+
+
+
+ delta_child_flow3
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/03 16:10:48.509
+ -
+ 2025/06/03 16:10:48.509
+
+
+
+
+
+ Table input
+ Insert / update
+ Y
+
+
+
+ Insert / update
+ InsertUpdate
+
+ Y
+
+ 1
+
+ none
+
+
+ 100
+ ervu-dashboard
+
+
+ =
+ recruit_id
+ recruit_id
+
+ ervu_dashboard
+
+
+ recruit_id
+ recruit_id
+ N
+
+
+ birth_az_number
+ birth_az_number
+ Y
+
+
+ birth_date
+ birth_date
+ Y
+
+
+ death_az_number
+ death_az_number
+ Y
+
+
+ death_date
+ death_date
+ Y
+
+
+ full_name
+ full_name
+ Y
+
+
+ kinship_type
+ kinship_type
+ Y
+
+
+ N
+
+
+ 1168
+ 352
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ with child as
+(select jsonb_array_elements(ri.info->'svedFL'->'svedDeti'->'rebenok') ch,
+ ri.recruit_id
+from ervu_dashboard.recruits_info ri
+join ervu_dashboard.citizen r ON r.recruit_id = ri.recruit_id AND '${ID_F3}' != '' -- Проверка на пустую строку
+ AND COALESCE(ri.current_recruitment_id, ri.target_recruitment_id) = '${ID_F3}'
+ AND '${M_R_CR_DATE}'::timestamp >= ri.created_at
+ AND ri.updated_at >= '${M_R_UP_DATE}'::timestamp
+where jsonb_typeof(ri.info->'svedFL'->'svedDeti'->'rebenok') = 'array'
+)
+select
+ r.recruit_id::uuid recruit_id,
+ ch->>'naimRodstvSvyazReb' kinship_type,
+ concat_ws(' ', ch->'svedFLBS'->'fio'->>'familiya',
+ ch->'svedFLBS'->'fio'->>'imya',
+ ch->'svedFLBS'->'fio'->>'otchestvo') full_name,
+ make_date(NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'god', '')::int,
+ NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'mesyacz','')::int,
+ NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'den','')::int) birth_date,
+ make_date(NULLIF(ch->'svedSmert'->'dataSmert'->>'god', '')::int,
+ NULLIF(ch->'svedSmert'->'dataSmert'->>'mesyacz','')::int,
+ NULLIF(ch->'svedSmert'->'dataSmert'->>'den','')::int) death_date,
+ ch->'svedSmert'->>'nomerZapis' death_az_number,
+ ch->'svedAZRozhd'->>'nomerZapis' birth_az_number
+from ervu_dashboard.citizen r
+join child on r.recruit_id = child.recruit_id
+ Y
+
+
+ 624
+ 352
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow4.hpl b/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow4.hpl
new file mode 100644
index 0000000..32b4002
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow4.hpl
@@ -0,0 +1,143 @@
+
+
+
+ delta_child_flow4
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/03 16:10:48.509
+ -
+ 2025/06/03 16:10:48.509
+
+
+
+
+
+ Table input
+ Insert / update
+ Y
+
+
+
+ Insert / update
+ InsertUpdate
+
+ Y
+
+ 1
+
+ none
+
+
+ 100
+ ervu-dashboard
+
+
+ =
+ recruit_id
+ recruit_id
+
+ ervu_dashboard
+
+
+ recruit_id
+ recruit_id
+ N
+
+
+ birth_az_number
+ birth_az_number
+ Y
+
+
+ birth_date
+ birth_date
+ Y
+
+
+ death_az_number
+ death_az_number
+ Y
+
+
+ death_date
+ death_date
+ Y
+
+
+ full_name
+ full_name
+ Y
+
+
+ kinship_type
+ kinship_type
+ Y
+
+
+ N
+
+
+ 1168
+ 352
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ with child as
+(select jsonb_array_elements(ri.info->'svedFL'->'svedDeti'->'rebenok') ch,
+ ri.recruit_id
+from ervu_dashboard.recruits_info ri
+join ervu_dashboard.citizen r ON r.recruit_id = ri.recruit_id AND '${ID_F4}' != '' -- Проверка на пустую строку
+ AND COALESCE(ri.current_recruitment_id, ri.target_recruitment_id) = '${ID_F4}'
+ AND '${M_R_CR_DATE}'::timestamp >= ri.created_at
+ AND ri.updated_at >= '${M_R_UP_DATE}'::timestamp
+where jsonb_typeof(ri.info->'svedFL'->'svedDeti'->'rebenok') = 'array'
+)
+select
+ r.recruit_id::uuid recruit_id,
+ ch->>'naimRodstvSvyazReb' kinship_type,
+ concat_ws(' ', ch->'svedFLBS'->'fio'->>'familiya',
+ ch->'svedFLBS'->'fio'->>'imya',
+ ch->'svedFLBS'->'fio'->>'otchestvo') full_name,
+ make_date(NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'god', '')::int,
+ NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'mesyacz','')::int,
+ NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'den','')::int) birth_date,
+ make_date(NULLIF(ch->'svedSmert'->'dataSmert'->>'god', '')::int,
+ NULLIF(ch->'svedSmert'->'dataSmert'->>'mesyacz','')::int,
+ NULLIF(ch->'svedSmert'->'dataSmert'->>'den','')::int) death_date,
+ ch->'svedSmert'->>'nomerZapis' death_az_number,
+ ch->'svedAZRozhd'->>'nomerZapis' birth_az_number
+from ervu_dashboard.citizen r
+join child on r.recruit_id = child.recruit_id
+ Y
+
+
+ 624
+ 352
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow5.hpl b/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow5.hpl
new file mode 100644
index 0000000..1a55d69
--- /dev/null
+++ b/mappings/info_recruits/citizen_tables/child/parallel/delta_child_flow5.hpl
@@ -0,0 +1,143 @@
+
+
+
+ delta_child_flow5
+ Y
+
+
+
+ Normal
+
+
+ N
+ 1000
+ 100
+ -
+ 2025/06/03 16:10:48.509
+ -
+ 2025/06/03 16:10:48.509
+
+
+
+
+
+ Table input
+ Insert / update
+ Y
+
+
+
+ Insert / update
+ InsertUpdate
+
+ Y
+
+ 1
+
+ none
+
+
+ 100
+ ervu-dashboard
+
+
+ =
+ recruit_id
+ recruit_id
+
+ ervu_dashboard
+
+
+ recruit_id
+ recruit_id
+ N
+
+
+ birth_az_number
+ birth_az_number
+ Y
+
+
+ birth_date
+ birth_date
+ Y
+
+
+ death_az_number
+ death_az_number
+ Y
+
+
+ death_date
+ death_date
+ Y
+
+
+ full_name
+ full_name
+ Y
+
+
+ kinship_type
+ kinship_type
+ Y
+
+
+ N
+
+
+ 1168
+ 352
+
+
+
+ Table input
+ TableInput
+
+ Y
+
+ 1
+
+ none
+
+
+ ervu-dashboard
+ N
+ 0
+ with child as
+(select jsonb_array_elements(ri.info->'svedFL'->'svedDeti'->'rebenok') ch,
+ ri.recruit_id
+from ervu_dashboard.recruits_info ri
+join ervu_dashboard.citizen r ON r.recruit_id = ri.recruit_id AND '${ID_F5}' != '' -- Проверка на пустую строку
+ AND COALESCE(ri.current_recruitment_id, ri.target_recruitment_id) = '${ID_F5}'
+ AND '${M_R_CR_DATE}'::timestamp >= ri.created_at
+ AND ri.updated_at >= '${M_R_UP_DATE}'::timestamp
+where jsonb_typeof(ri.info->'svedFL'->'svedDeti'->'rebenok') = 'array'
+)
+select
+ r.recruit_id::uuid recruit_id,
+ ch->>'naimRodstvSvyazReb' kinship_type,
+ concat_ws(' ', ch->'svedFLBS'->'fio'->>'familiya',
+ ch->'svedFLBS'->'fio'->>'imya',
+ ch->'svedFLBS'->'fio'->>'otchestvo') full_name,
+ make_date(NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'god', '')::int,
+ NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'mesyacz','')::int,
+ NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'den','')::int) birth_date,
+ make_date(NULLIF(ch->'svedSmert'->'dataSmert'->>'god', '')::int,
+ NULLIF(ch->'svedSmert'->'dataSmert'->>'mesyacz','')::int,
+ NULLIF(ch->'svedSmert'->'dataSmert'->>'den','')::int) death_date,
+ ch->'svedSmert'->>'nomerZapis' death_az_number,
+ ch->'svedAZRozhd'->>'nomerZapis' birth_az_number
+from ervu_dashboard.citizen r
+join child on r.recruit_id = child.recruit_id
+ Y
+
+
+ 624
+ 352
+
+
+
+
+
+
diff --git a/mappings/info_recruits/citizen_tables/child/recruitment_rows_five_flow_if_error.hpl b/mappings/info_recruits/citizen_tables/child/recruitment_rows_five_flow_if_error.hpl
index e5f247b..0a663c3 100644
--- a/mappings/info_recruits/citizen_tables/child/recruitment_rows_five_flow_if_error.hpl
+++ b/mappings/info_recruits/citizen_tables/child/recruitment_rows_five_flow_if_error.hpl
@@ -57,7 +57,17 @@
ervu-dashboard
N
0
- WITH ordered AS (
+ WITH
+fr_check AS (
+ SELECT
+ last_recruitment_id AS recruitment_id,
+ recruitment_created_date,
+ status,
+ job_name
+ FROM public.etl_checkpoints
+ WHERE status = 'ERROR' AND job_name IN ('child_flow1', 'child_flow2', 'child_flow3', 'child_flow4', 'child_flow5')
+),
+ordered AS (
SELECT
idm_id,
created_at,
@@ -68,132 +78,46 @@
splitted AS (
SELECT *,
CEIL(total_rows / 5.0) AS part_size,
- FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
+ FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num,
+ ((rn - 1) % CEIL(total_rows / 5.0)) + 1 AS position
FROM ordered
),
-flow_ranges AS (
- SELECT
- flow_num,
- MIN(created_at) AS min_date,
- MAX(created_at) AS max_date
+pivoted AS (
+ SELECT
+ position,
+ MAX(CASE WHEN flow_num = 1 AND created_at >= (SELECT recruitment_created_date FROM fr_check WHERE job_name = 'child_flow1') THEN created_at END) AS cr_flow1,
+ MAX(CASE WHEN flow_num = 1 AND created_at >= (SELECT recruitment_created_date FROM fr_check WHERE job_name = 'child_flow1') THEN idm_id::text END) AS idm_flow1,
+ MAX(CASE WHEN flow_num = 2 AND created_at >= (SELECT recruitment_created_date FROM fr_check WHERE job_name = 'child_flow2') THEN created_at END) AS cr_flow2,
+ MAX(CASE WHEN flow_num = 2 AND created_at >= (SELECT recruitment_created_date FROM fr_check WHERE job_name = 'child_flow2') THEN idm_id::text END) AS idm_flow2,
+ MAX(CASE WHEN flow_num = 3 AND created_at >= (SELECT recruitment_created_date FROM fr_check WHERE job_name = 'child_flow3') THEN created_at END) AS cr_flow3,
+ MAX(CASE WHEN flow_num = 3 AND created_at >= (SELECT recruitment_created_date FROM fr_check WHERE job_name = 'child_flow3') THEN idm_id::text END) AS idm_flow3,
+ MAX(CASE WHEN flow_num = 4 AND created_at >= (SELECT recruitment_created_date FROM fr_check WHERE job_name = 'child_flow4') THEN created_at END) AS cr_flow4,
+ MAX(CASE WHEN flow_num = 4 AND created_at >= (SELECT recruitment_created_date FROM fr_check WHERE job_name = 'child_flow4') THEN idm_id::text END) AS idm_flow4,
+ MAX(CASE WHEN flow_num = 5 AND created_at >= (SELECT recruitment_created_date FROM fr_check WHERE job_name = 'child_flow5') THEN created_at END) AS cr_flow5,
+ MAX(CASE WHEN flow_num = 5 AND created_at >= (SELECT recruitment_created_date FROM fr_check WHERE job_name = 'child_flow5') THEN idm_id::text END) AS idm_flow5
FROM splitted
- GROUP BY flow_num
-),
-recr_inf AS (
- SELECT DISTINCT COALESCE(cit.recruitment_id, cit.target_recruitment_id) AS idm_id
- FROM ervu_dashboard.citizen cit
- join ervu_dashboard.citizen_child ch on ch.recruit_id = cit.recruit_id
-
-),
-flow_data AS (
- SELECT
- fr.flow_num,
- ri.idm_id,
- (SELECT r.created_at FROM ervu_dashboard.recruitment r
- WHERE r.idm_id = ri.idm_id
- AND r.created_at BETWEEN fr.min_date AND fr.max_date
- LIMIT 1) AS created_at
- FROM recr_inf ri
- CROSS JOIN flow_ranges fr
- WHERE EXISTS (
- SELECT 1 FROM ervu_dashboard.recruitment r
- WHERE r.idm_id = ri.idm_id
- )
-),
-result_ma as (
- SELECT
- MAX(created_at) FILTER(WHERE flow_num = 1) AS cr_flow1,
- (SELECT idm_id FROM flow_data WHERE flow_num = 1 ORDER BY created_at DESC NULLS LAST LIMIT 1) AS idm_flow1,
-
- MAX(created_at) FILTER(WHERE flow_num = 2) AS cr_flow2,
- (SELECT idm_id FROM flow_data WHERE flow_num = 2 ORDER BY created_at DESC NULLS LAST LIMIT 1) AS idm_flow2,
-
- MAX(created_at) FILTER(WHERE flow_num = 3) AS cr_flow3,
- (SELECT idm_id FROM flow_data WHERE flow_num = 3 ORDER BY created_at DESC NULLS LAST LIMIT 1) AS idm_flow3,
-
- MAX(created_at) FILTER(WHERE flow_num = 4) AS cr_flow4,
- (SELECT idm_id FROM flow_data WHERE flow_num = 4 ORDER BY created_at DESC NULLS LAST LIMIT 1) AS idm_flow4,
-
- MAX(created_at) FILTER(WHERE flow_num = 5) AS cr_flow5,
- (SELECT idm_id FROM flow_data WHERE flow_num = 5 ORDER BY created_at DESC NULLS LAST LIMIT 1) AS idm_flow5
- FROM flow_data
-),
-result_max as ( --костыль
- SELECT
- CASE
- WHEN cr_flow1 is null THEN '0001-01-01 00:00:00'::timestamp
- ELSE cr_flow1
- END AS cr_flow1,
- idm_flow1,
- CASE
- WHEN cr_flow2 is null THEN '0001-01-01 00:00:00'::timestamp
- ELSE cr_flow2
- END AS cr_flow2,
- idm_flow2,
- CASE
- WHEN cr_flow3 is null THEN '0001-01-01 00:00:00'::timestamp
- ELSE cr_flow3
- END AS cr_flow3,
- idm_flow3,
- CASE
- WHEN cr_flow4 is null THEN '0001-01-01 00:00:00'::timestamp
- ELSE cr_flow4
- END AS cr_flow4,
- idm_flow4,
- CASE
- WHEN cr_flow5 is null THEN '0001-01-01 00:00:00'::timestamp
- ELSE cr_flow5
- END AS cr_flow5,
- idm_flow5
- FROM result_ma
+ GROUP BY position
),
remains as (
- select
- CASE
- WHEN created_at >= (select cr_flow1 from result_max) and flow_num = 1 THEN created_at
- ELSE null
- END as cr_flow1,
- CASE
- WHEN created_at >= (select cr_flow1 from result_max) and flow_num = 1 THEN idm_id
- ELSE null
- END as idm_flow1,
-
- CASE
- WHEN created_at >= (select cr_flow2 from result_max) and flow_num = 2 THEN created_at
- ELSE null
- END as cr_flow2,
- CASE
- WHEN created_at >= (select cr_flow2 from result_max) and flow_num = 2 THEN idm_id
- ELSE null
- END as idm_flow2,
-
- CASE
- WHEN created_at >= (select cr_flow3 from result_max) and flow_num = 3 THEN created_at
- ELSE null
- END as cr_flow3,
- CASE
- WHEN created_at >= (select cr_flow3 from result_max) and flow_num = 3 THEN idm_id
- ELSE null
- END as idm_flow3,
-
- CASE
- WHEN created_at >= (select cr_flow4 from result_max) and flow_num = 4 THEN created_at
- ELSE null
- END as cr_flow4,
- CASE
- WHEN created_at >= (select cr_flow4 from result_max) and flow_num = 4 THEN idm_id
- ELSE null
- END as idm_flow4,
-
- CASE
- WHEN created_at >= (select cr_flow5 from result_max) and flow_num = 5 THEN created_at
- ELSE null
- END as cr_flow5,
- CASE
- WHEN created_at >= (select cr_flow5 from result_max) and flow_num = 5 THEN idm_id
- ELSE null
- END as idm_flow5
- from splitted
+ SELECT
+ position,
+ cr_flow1,
+ idm_flow1::uuid,
+ cr_flow2,
+ idm_flow2::uuid,
+ cr_flow3,
+ idm_flow3::uuid,
+ cr_flow4,
+ idm_flow4::uuid,
+ cr_flow5,
+ idm_flow5::uuid
+ FROM pivoted
+ WHERE (cr_flow1 IS NOT NULL AND idm_flow1 IS NOT NULL)
+ OR (cr_flow2 IS NOT NULL AND idm_flow2 IS NOT NULL)
+ OR (cr_flow3 IS NOT NULL AND idm_flow3 IS NOT NULL)
+ OR (cr_flow4 IS NOT NULL AND idm_flow4 IS NOT NULL)
+ OR (cr_flow5 IS NOT NULL AND idm_flow5 IS NOT NULL)
+ order by position
),
idm1 as (
select
diff --git a/mappings/info_recruits/raw_data/info_recruits/job_recruits_info.hwf b/mappings/info_recruits/raw_data/info_recruits/job_recruits_info.hwf
index 2fc61be..c9b5aec 100644
--- a/mappings/info_recruits/raw_data/info_recruits/job_recruits_info.hwf
+++ b/mappings/info_recruits/raw_data/info_recruits/job_recruits_info.hwf
@@ -1891,7 +1891,7 @@
variable
STATUS
N
- 1840
+ 1824
2944
diff --git a/mappings/mil_com/job_recruitments_milcom.hwf b/mappings/mil_com/job_recruitments_milcom.hwf
index f429311..e70eb4f 100644
--- a/mappings/mil_com/job_recruitments_milcom.hwf
+++ b/mappings/mil_com/job_recruitments_milcom.hwf
@@ -693,8 +693,6 @@ WHERE recording_date = current_date
N
N
${PROJECT_HOME}/mil_com/main_dashboard.recruitment_campaign(m_c)/main_dashboard.recruitment_campaign(m_c).hwf
-
-
Nothing
Y
@@ -1888,7 +1886,7 @@ WHERE recording_date = current_date
Start
recruitment_campaign.subpoenas(m_c).hwf
- Y
+ N
Y
Y