Merge remote-tracking branch 'origin/develop' into ERVU-506_addr
# Conflicts: # map_v1/info_recruits/citizen_tables/citizen/parallel/citizen_flow1.hpl # map_v1/info_recruits/citizen_tables/citizen/parallel/citizen_flow2.hpl # map_v1/info_recruits/citizen_tables/citizen/parallel/citizen_flow3.hpl # map_v1/info_recruits/citizen_tables/citizen/parallel/citizen_flow4.hpl # map_v1/info_recruits/citizen_tables/citizen/parallel/citizen_flow5.hpl # map_v1/info_recruits/citizen_tables/citizen/parallel/delta_citizen_flow1.hpl # map_v1/info_recruits/citizen_tables/citizen/parallel/delta_citizen_flow2.hpl # map_v1/info_recruits/citizen_tables/citizen/parallel/delta_citizen_flow3.hpl # map_v1/info_recruits/citizen_tables/citizen/parallel/delta_citizen_flow4.hpl # map_v1/info_recruits/citizen_tables/citizen/parallel/delta_citizen_flow5.hpl
This commit is contained in:
commit
b2f0e2bf25
474 changed files with 60591 additions and 71488 deletions
|
|
@ -201,6 +201,11 @@
|
|||
<rename>id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>marital_status</name>
|
||||
<rename>marital_status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
|
|
@ -279,7 +284,7 @@
|
|||
r.vu_current_info,
|
||||
r.military_registration_date AS date_registration,
|
||||
r.vu_unset_date AS date_deregistration,
|
||||
--ri.info->'svedFL'->'svedSemPolozh'->>'semPolozhNaim' AS marital_status,
|
||||
NULLIF(ri.info->'svedFL'->'svedSemPolozh'->>'semPolozh','')::int AS marital_status,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'nomDok' AS passport_number,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'serDok' AS passport_series,
|
||||
--ri.info->'svedFL'->'svedVoin'->'voin'->>'dataReg' AS issue_date,
|
||||
|
|
|
|||
|
|
@ -44,6 +44,7 @@
|
|||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
<name2/>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen</table>
|
||||
|
|
@ -157,6 +158,11 @@
|
|||
<rename>id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>marital_status</name>
|
||||
<rename>marital_status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
|
|
@ -198,7 +204,7 @@
|
|||
r.vu_current_info,
|
||||
r.military_registration_date AS date_registration,
|
||||
r.vu_unset_date AS date_deregistration,
|
||||
--ri.info->'svedFL'->'svedSemPolozh'->>'semPolozhNaim' AS marital_status,
|
||||
NULLIF(ri.info->'svedFL'->'svedSemPolozh'->>'semPolozh','')::int AS marital_status,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'nomDok' AS passport_number,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'serDok' AS passport_series,
|
||||
--ri.info->'svedFL'->'svedVoin'->'voin'->>'dataReg' AS issue_date,
|
||||
|
|
|
|||
|
|
@ -44,6 +44,7 @@
|
|||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
<name2/>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen</table>
|
||||
|
|
@ -157,11 +158,16 @@
|
|||
<rename>id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>marital_status</name>
|
||||
<rename>marital_status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1248</xloc>
|
||||
<xloc>1264</xloc>
|
||||
<yloc>416</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
|
|
@ -198,7 +204,7 @@
|
|||
r.vu_current_info,
|
||||
r.military_registration_date AS date_registration,
|
||||
r.vu_unset_date AS date_deregistration,
|
||||
--ri.info->'svedFL'->'svedSemPolozh'->>'semPolozhNaim' AS marital_status,
|
||||
NULLIF(ri.info->'svedFL'->'svedSemPolozh'->>'semPolozh','')::int AS marital_status,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'nomDok' AS passport_number,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'serDok' AS passport_series,
|
||||
--ri.info->'svedFL'->'svedVoin'->'voin'->>'dataReg' AS issue_date,
|
||||
|
|
|
|||
|
|
@ -44,6 +44,7 @@
|
|||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
<name2/>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen</table>
|
||||
|
|
@ -157,11 +158,16 @@
|
|||
<rename>id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>marital_status</name>
|
||||
<rename>marital_status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<xloc>1216</xloc>
|
||||
<yloc>432</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
|
|
@ -198,7 +204,7 @@
|
|||
r.vu_current_info,
|
||||
r.military_registration_date AS date_registration,
|
||||
r.vu_unset_date AS date_deregistration,
|
||||
--ri.info->'svedFL'->'svedSemPolozh'->>'semPolozhNaim' AS marital_status,
|
||||
NULLIF(ri.info->'svedFL'->'svedSemPolozh'->>'semPolozh','')::int AS marital_status,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'nomDok' AS passport_number,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'serDok' AS passport_series,
|
||||
--ri.info->'svedFL'->'svedVoin'->'voin'->>'dataReg' AS issue_date,
|
||||
|
|
|
|||
|
|
@ -44,6 +44,7 @@
|
|||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
<name2/>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen</table>
|
||||
|
|
@ -157,11 +158,16 @@
|
|||
<rename>id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>marital_status</name>
|
||||
<rename>marital_status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1216</xloc>
|
||||
<xloc>1248</xloc>
|
||||
<yloc>416</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
|
|
@ -198,7 +204,7 @@
|
|||
r.vu_current_info,
|
||||
r.military_registration_date AS date_registration,
|
||||
r.vu_unset_date AS date_deregistration,
|
||||
--ri.info->'svedFL'->'svedSemPolozh'->>'semPolozhNaim' AS marital_status,
|
||||
NULLIF(ri.info->'svedFL'->'svedSemPolozh'->>'semPolozh','')::int AS marital_status,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'nomDok' AS passport_number,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'serDok' AS passport_series,
|
||||
--ri.info->'svedFL'->'svedVoin'->'voin'->>'dataReg' AS issue_date,
|
||||
|
|
|
|||
|
|
@ -158,6 +158,11 @@
|
|||
<rename>id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>marital_status</name>
|
||||
<rename>marital_status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
|
|
@ -199,7 +204,7 @@
|
|||
--r.vu_current_info,
|
||||
r.military_registration_date AS date_registration,
|
||||
r.vu_unset_date AS date_deregistration,
|
||||
--ri.info->'svedFL'->'svedSemPolozh'->>'semPolozhNaim' AS marital_status,
|
||||
NULLIF(ri.info->'svedFL'->'svedSemPolozh'->>'semPolozh','')::int AS marital_status,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'nomDok' AS passport_number,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'serDok' AS passport_series,
|
||||
--ri.info->'svedFL'->'svedVoin'->'voin'->>'dataReg' AS issue_date,
|
||||
|
|
|
|||
|
|
@ -158,6 +158,11 @@
|
|||
<rename>id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>marital_status</name>
|
||||
<rename>marital_status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
|
|
@ -199,7 +204,7 @@
|
|||
--r.vu_current_info,
|
||||
r.military_registration_date AS date_registration,
|
||||
r.vu_unset_date AS date_deregistration,
|
||||
--ri.info->'svedFL'->'svedSemPolozh'->>'semPolozhNaim' AS marital_status,
|
||||
NULLIF(ri.info->'svedFL'->'svedSemPolozh'->>'semPolozh','')::int AS marital_status,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'nomDok' AS passport_number,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'serDok' AS passport_series,
|
||||
--ri.info->'svedFL'->'svedVoin'->'voin'->>'dataReg' AS issue_date,
|
||||
|
|
|
|||
|
|
@ -158,6 +158,11 @@
|
|||
<rename>id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>marital_status</name>
|
||||
<rename>marital_status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
|
|
@ -199,7 +204,7 @@
|
|||
--r.vu_current_info,
|
||||
r.military_registration_date AS date_registration,
|
||||
r.vu_unset_date AS date_deregistration,
|
||||
--ri.info->'svedFL'->'svedSemPolozh'->>'semPolozhNaim' AS marital_status,
|
||||
NULLIF(ri.info->'svedFL'->'svedSemPolozh'->>'semPolozh','')::int AS marital_status,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'nomDok' AS passport_number,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'serDok' AS passport_series,
|
||||
--ri.info->'svedFL'->'svedVoin'->'voin'->>'dataReg' AS issue_date,
|
||||
|
|
|
|||
|
|
@ -158,6 +158,11 @@
|
|||
<rename>id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>marital_status</name>
|
||||
<rename>marital_status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
|
|
@ -199,7 +204,7 @@
|
|||
--r.vu_current_info,
|
||||
r.military_registration_date AS date_registration,
|
||||
r.vu_unset_date AS date_deregistration,
|
||||
--ri.info->'svedFL'->'svedSemPolozh'->>'semPolozhNaim' AS marital_status,
|
||||
NULLIF(ri.info->'svedFL'->'svedSemPolozh'->>'semPolozh','')::int AS marital_status,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'nomDok' AS passport_number,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'serDok' AS passport_series,
|
||||
--ri.info->'svedFL'->'svedVoin'->'voin'->>'dataReg' AS issue_date,
|
||||
|
|
|
|||
|
|
@ -158,6 +158,11 @@
|
|||
<rename>id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>marital_status</name>
|
||||
<rename>marital_status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
|
|
@ -199,7 +204,7 @@
|
|||
--r.vu_current_info,
|
||||
r.military_registration_date AS date_registration,
|
||||
r.vu_unset_date AS date_deregistration,
|
||||
--ri.info->'svedFL'->'svedSemPolozh'->>'semPolozhNaim' AS marital_status,
|
||||
NULLIF(ri.info->'svedFL'->'svedSemPolozh'->>'semPolozh','')::int AS marital_status,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'nomDok' AS passport_number,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'serDok' AS passport_series,
|
||||
--ri.info->'svedFL'->'svedVoin'->'voin'->>'dataReg' AS issue_date,
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_citizen_liability_fz53_flow2_error</name>
|
||||
<name>recruit_update_date_ervu_dashboard</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
|
|
@ -13,63 +13,19 @@
|
|||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<created_date>2025/06/02 14:50:31.833</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
<modified_date>2025/06/02 14:50:31.833</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<to>Table output</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
|
|
@ -85,14 +41,51 @@
|
|||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT
|
||||
'delta_citizen_liability_fz53_flow2' as job_name,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
</sql>
|
||||
created_at AS system_create_date,
|
||||
updated_at AS system_update_date,
|
||||
current_timestamp AS record_created,
|
||||
'job_recruits_info' AS workflow
|
||||
FROM ervu_dashboard.recruits_info
|
||||
WHERE updated_at = (SELECT MAX(updated_at) FROM ervu_dashboard.recruits_info)
|
||||
limit 1</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<xloc>896</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table output</name>
|
||||
<type>TableOutput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>1000</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<fields>
|
||||
</fields>
|
||||
<ignore_errors>N</ignore_errors>
|
||||
<only_when_have_rows>N</only_when_have_rows>
|
||||
<partitioning_daily>N</partitioning_daily>
|
||||
<partitioning_enabled>N</partitioning_enabled>
|
||||
<partitioning_monthly>Y</partitioning_monthly>
|
||||
<return_keys>N</return_keys>
|
||||
<schema>public</schema>
|
||||
<specify_fields>N</specify_fields>
|
||||
<table>recruit_create</table>
|
||||
<tablename_in_field>N</tablename_in_field>
|
||||
<tablename_in_table>Y</tablename_in_table>
|
||||
<truncate>N</truncate>
|
||||
<use_batch>Y</use_batch>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1216</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@
|
|||
"description" : ""
|
||||
}, {
|
||||
"name" : "DB_DASHBOARD_NAME",
|
||||
"value" : "ervu-dashboard-test1",
|
||||
"value" : "ervu-dashboard-test",
|
||||
"description" : ""
|
||||
}, {
|
||||
"name" : "DB_DASHBOARD_USERNAME",
|
||||
|
|
|
|||
|
|
@ -1,124 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>branching_child</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/09 09:54:43.724</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/09 09:54:43.724</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Set variables 2</from>
|
||||
<to>Write to log 2</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Set variables 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Set variables 2</name>
|
||||
<type>SetVariable</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<fields>
|
||||
<field>
|
||||
<field_name>pipeline</field_name>
|
||||
<variable_name>PIPE</variable_name>
|
||||
<variable_type>PARENT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
<field>
|
||||
<field_name>status</field_name>
|
||||
<variable_name>STATUS</variable_name>
|
||||
<variable_type>PARENT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
</fields>
|
||||
<use_formatting>Y</use_formatting>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>256</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>select
|
||||
status as STATUS,
|
||||
job_name AS PIPELINE
|
||||
from public.etl_checkpoints
|
||||
where job_name = 'job_child'</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>816</xloc>
|
||||
<yloc>256</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Write to log 2</name>
|
||||
<type>WriteToLog</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<displayHeader>Y</displayHeader>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
</field>
|
||||
</fields>
|
||||
<limitRows>N</limitRows>
|
||||
<limitRowsNumber>0</limitRowsNumber>
|
||||
<loglevel>Basic</loglevel>
|
||||
<logmessage>${PIPE}
|
||||
${STATUS}</logmessage>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1280</xloc>
|
||||
<yloc>256</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,142 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>branching_child_delta</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/09 09:54:43.724</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/09 09:54:43.724</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Set variables 2</from>
|
||||
<to>Write to log 2</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Set variables 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Set variables 2</name>
|
||||
<type>SetVariable</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<fields>
|
||||
<field>
|
||||
<field_name>pipeline</field_name>
|
||||
<variable_name>PIPE</variable_name>
|
||||
<variable_type>PARENT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
<field>
|
||||
<field_name>status</field_name>
|
||||
<variable_name>STATUS</variable_name>
|
||||
<variable_type>PARENT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
</fields>
|
||||
<use_formatting>Y</use_formatting>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>256</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>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</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>816</xloc>
|
||||
<yloc>256</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Write to log 2</name>
|
||||
<type>WriteToLog</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<displayHeader>Y</displayHeader>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
</field>
|
||||
</fields>
|
||||
<limitRows>N</limitRows>
|
||||
<limitRowsNumber>0</limitRowsNumber>
|
||||
<loglevel>Basic</loglevel>
|
||||
<logmessage>${PIPE}
|
||||
${STATUS}</logmessage>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1280</xloc>
|
||||
<yloc>256</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_child_flow1_error</name>
|
||||
<name>check_if_need_to_repeat_job</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
|
|
@ -13,22 +13,22 @@
|
|||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<created_date>2025/08/08 12:27:51.630</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
<modified_date>2025/08/08 12:27:51.630</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<to>Set variables</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<name>Set variables</name>
|
||||
<type>SetVariable</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
|
|
@ -37,37 +37,18 @@
|
|||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<fields>
|
||||
<field>
|
||||
<field_name>need_to_repeat_job</field_name>
|
||||
<variable_name>NEED_TO_REPEAT_JOB</variable_name>
|
||||
<variable_type>ROOT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
</fields>
|
||||
<use_formatting>Y</use_formatting>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
<xloc>624</xloc>
|
||||
<yloc>288</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
|
|
@ -84,15 +65,19 @@
|
|||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_child_flow1' as job_name,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created</sql>
|
||||
<sql>SELECT EXISTS (SELECT 1
|
||||
FROM ervu_dashboard.recruitment r
|
||||
LEFT JOIN etl.job_execution je
|
||||
ON r.idm_id = je.recruitment_id
|
||||
and job_name = 'child_job'
|
||||
where je.status is null or je.status in ('ERROR', 'PROCESSING')
|
||||
limit 1
|
||||
) as need_to_repeat_job;</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
<xloc>336</xloc>
|
||||
<yloc>288</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
|
|
@ -1,250 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_child_flow1_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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
|
||||
),
|
||||
for_checkpoints as (
|
||||
SELECT
|
||||
'child_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,250 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_child_flow1_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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
|
||||
),
|
||||
for_checkpoints as (
|
||||
SELECT
|
||||
'child_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,254 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_child_flow2_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'child_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,254 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_child_flow2_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'child_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,255 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_child_flow3_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'child_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,255 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_child_flow3_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'child_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,256 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_child_flow4_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'child_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,256 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_child_flow4_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'child_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,256 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_child_flow5_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'child_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,256 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_child_flow5_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'child_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,103 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_child_flow1_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_child_flow1' as job_name,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
|
||||
</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,103 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_child_flow3_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_child_flow3' as job_name,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
|
||||
</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,103 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_child_flow4_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_child_flow4' as job_name,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
|
||||
</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,101 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_child_flow5_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_child_flow5' as job_name,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,103 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_child_flow5_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_child_flow5' as job_name,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
|
||||
</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,142 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_to_processing</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/11 16:14:31.162</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/11 16:14:31.162</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT
|
||||
'PROCESSING' AS status,
|
||||
'job_child' AS job_name,
|
||||
current_timestamp AS record_created
|
||||
--FROM public.etl_checkpoints
|
||||
|
||||
UNION ALL
|
||||
|
||||
SELECT
|
||||
'PROCESSING' AS status,
|
||||
'child_flow1' AS job_name,
|
||||
current_timestamp AS record_created
|
||||
--FROM public.etl_checkpoints
|
||||
|
||||
UNION ALL
|
||||
|
||||
SELECT
|
||||
'PROCESSING' AS status,
|
||||
'child_flow2' AS job_name,
|
||||
current_timestamp AS record_created
|
||||
--FROM public.etl_checkpoints
|
||||
|
||||
UNION ALL
|
||||
|
||||
SELECT
|
||||
'PROCESSING' AS status,
|
||||
'child_flow3' AS job_name,
|
||||
current_timestamp AS record_created
|
||||
--FROM public.etl_checkpoints
|
||||
|
||||
UNION ALL
|
||||
|
||||
SELECT
|
||||
'PROCESSING' AS status,
|
||||
'child_flow4' AS job_name,
|
||||
current_timestamp AS record_created
|
||||
--FROM public.etl_checkpoints
|
||||
|
||||
UNION ALL
|
||||
|
||||
SELECT
|
||||
'PROCESSING' AS status,
|
||||
'child_flow5' AS job_name,
|
||||
current_timestamp AS record_created
|
||||
--FROM public.etl_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>368</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,142 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_to_processing_delta</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 13:42:26.494</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 13:42:26.494</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1248</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT
|
||||
'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</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>832</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -0,0 +1,113 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>check_if_child_job_exists</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/08/05 13:28:46.661</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/08/05 13:28:46.661</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Set variables</from>
|
||||
<to>Write to log</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Set variables</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Set variables</name>
|
||||
<type>SetVariable</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<fields>
|
||||
<field>
|
||||
<field_name>job_executed_flag</field_name>
|
||||
<variable_name>JOB_EXECUTED_FLAG</variable_name>
|
||||
<variable_type>PARENT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
</fields>
|
||||
<use_formatting>Y</use_formatting>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>672</xloc>
|
||||
<yloc>336</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT EXISTS (
|
||||
SELECT 1
|
||||
FROM etl.job_execution
|
||||
WHERE job_name = 'child_job'
|
||||
limit 1
|
||||
) AS job_executed_flag;</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>384</xloc>
|
||||
<yloc>336</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Write to log</name>
|
||||
<type>WriteToLog</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<loglevel>Basic</loglevel>
|
||||
<displayHeader>Y</displayHeader>
|
||||
<limitRows>N</limitRows>
|
||||
<limitRowsNumber>0</limitRowsNumber>
|
||||
<logmessage>${STATUS}</logmessage>
|
||||
<fields>
|
||||
</fields>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>944</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,273 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>checkpoint_child_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/09 10:01:04.895</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/09 10:01:04.895</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Select values</from>
|
||||
<to>Table output</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Select values</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Table output</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Select values</name>
|
||||
<type>SelectValues</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<fields>
|
||||
<select_unspecified>N</select_unspecified>
|
||||
<meta>
|
||||
<name>idm_id</name>
|
||||
<rename>idm_id</rename>
|
||||
<type>String</type>
|
||||
<length>-2</length>
|
||||
<precision>-2</precision>
|
||||
<conversion_mask/>
|
||||
<date_format_lenient>false</date_format_lenient>
|
||||
<date_format_locale/>
|
||||
<date_format_timezone/>
|
||||
<lenient_string_to_number>false</lenient_string_to_number>
|
||||
<encoding/>
|
||||
<decimal_symbol/>
|
||||
<grouping_symbol/>
|
||||
<currency_symbol/>
|
||||
<storage_type/>
|
||||
</meta>
|
||||
</fields>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1008</xloc>
|
||||
<yloc>608</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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
|
||||
),
|
||||
for_checkpoints as (
|
||||
SELECT
|
||||
'job_child_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_child_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_child_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_child_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_child_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>736</xloc>
|
||||
<yloc>448</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table output</name>
|
||||
<type>TableOutput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>1000</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<fields>
|
||||
</fields>
|
||||
<ignore_errors>N</ignore_errors>
|
||||
<only_when_have_rows>N</only_when_have_rows>
|
||||
<partitioning_daily>N</partitioning_daily>
|
||||
<partitioning_enabled>N</partitioning_enabled>
|
||||
<partitioning_monthly>Y</partitioning_monthly>
|
||||
<return_keys>N</return_keys>
|
||||
<schema>public</schema>
|
||||
<specify_fields>N</specify_fields>
|
||||
<table>etl_checkpoints</table>
|
||||
<tablename_in_field>N</tablename_in_field>
|
||||
<tablename_in_table>Y</tablename_in_table>
|
||||
<truncate>N</truncate>
|
||||
<use_batch>Y</use_batch>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1248</xloc>
|
||||
<yloc>448</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,869 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>checkpoint_job_child</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/03 14:19:02.590</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/03 14:19:02.590</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Filter rows</from>
|
||||
<to>Abort</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow1.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow2.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow3.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow4.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow5.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow1.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow2.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow3.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow4.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow5.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Abort</name>
|
||||
<type>Abort</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<abort_option>ABORT_WITH_ERROR</abort_option>
|
||||
<always_log_rows>Y</always_log_rows>
|
||||
<row_threshold>0</row_threshold>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1264</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Dummy (do nothing)</name>
|
||||
<type>Dummy</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>352</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Filter rows</name>
|
||||
<type>FilterRows</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compare>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow2</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow3</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow4</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow5</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</compare>
|
||||
<send_true_to>Abort</send_true_to>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>944</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1264</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow1.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow1.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>432</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow2.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow2.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>512</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow3.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow3.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow4.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow4.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>672</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow5.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow5.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>752</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH status_check AS (
|
||||
SELECT
|
||||
bool_or(status = 'ERROR' AND job_name IN (
|
||||
'child_flow1',
|
||||
'child_flow2',
|
||||
'child_flow3',
|
||||
'child_flow4',
|
||||
'child_flow5'
|
||||
)) AS has_error,
|
||||
count(*) FILTER (
|
||||
WHERE status = 'SUCCESS' AND job_name IN (
|
||||
'child_flow1',
|
||||
'child_flow2',
|
||||
'child_flow3',
|
||||
'child_flow4',
|
||||
'child_flow5'
|
||||
)
|
||||
) = 5 AS all_success
|
||||
FROM public.etl_checkpoints
|
||||
)
|
||||
SELECT
|
||||
'job_child' 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;</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>896</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,869 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>checkpoint_job_child_delta</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/03 14:19:02.590</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/03 14:19:02.590</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Filter rows</from>
|
||||
<to>Abort</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow1.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow2.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow3.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow4.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow5.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow1.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow2.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow3.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow4.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow5.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Abort</name>
|
||||
<type>Abort</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<abort_option>ABORT_WITH_ERROR</abort_option>
|
||||
<always_log_rows>Y</always_log_rows>
|
||||
<row_threshold>0</row_threshold>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1264</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Dummy (do nothing)</name>
|
||||
<type>Dummy</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>352</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Filter rows</name>
|
||||
<type>FilterRows</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compare>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow2</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow3</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow4</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow5</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</compare>
|
||||
<send_true_to>Abort</send_true_to>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>944</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1264</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow1.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow1.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>432</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow2.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow2.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>512</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow3.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow3.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow4.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow4.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>672</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow5.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow5.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>752</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>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;</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>896</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,235 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<workflow>
|
||||
<name>job_create_files_child</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<workflow_version/>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/05/26 16:48:00.210</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/05/26 16:48:00.210</modified_date>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<actions>
|
||||
<action>
|
||||
<name>Start</name>
|
||||
<description/>
|
||||
<type>SPECIAL</type>
|
||||
<attributes/>
|
||||
<DayOfMonth>1</DayOfMonth>
|
||||
<hour>12</hour>
|
||||
<intervalMinutes>60</intervalMinutes>
|
||||
<intervalSeconds>0</intervalSeconds>
|
||||
<minutes>0</minutes>
|
||||
<repeat>N</repeat>
|
||||
<schedulerType>0</schedulerType>
|
||||
<weekDay>1</weekDay>
|
||||
<parallel>N</parallel>
|
||||
<xloc>576</xloc>
|
||||
<yloc>496</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>state_child_flow2_new</name>
|
||||
<description/>
|
||||
<type>WRITE_TO_FILE</type>
|
||||
<attributes/>
|
||||
<appendFile>N</appendFile>
|
||||
<content>{
|
||||
"status": "NEW",
|
||||
"pipeline": "child_flow2"
|
||||
}</content>
|
||||
<createParentFolder>N</createParentFolder>
|
||||
<encoding>UTF-8</encoding>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow2.json</filename>
|
||||
<parallel>N</parallel>
|
||||
<xloc>848</xloc>
|
||||
<yloc>416</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>state_child_flow1_new</name>
|
||||
<description/>
|
||||
<type>WRITE_TO_FILE</type>
|
||||
<attributes/>
|
||||
<appendFile>N</appendFile>
|
||||
<content>{
|
||||
"status": "NEW",
|
||||
"pipeline": "child_flow1"
|
||||
}</content>
|
||||
<createParentFolder>N</createParentFolder>
|
||||
<encoding>UTF-8</encoding>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow1.json</filename>
|
||||
<parallel>N</parallel>
|
||||
<xloc>848</xloc>
|
||||
<yloc>336</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>state_child_flow3_new</name>
|
||||
<description/>
|
||||
<type>WRITE_TO_FILE</type>
|
||||
<attributes/>
|
||||
<appendFile>N</appendFile>
|
||||
<content>{
|
||||
"status": "NEW",
|
||||
"pipeline": "child_flow3"
|
||||
}</content>
|
||||
<createParentFolder>N</createParentFolder>
|
||||
<encoding>UTF-8</encoding>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow3.json</filename>
|
||||
<parallel>N</parallel>
|
||||
<xloc>848</xloc>
|
||||
<yloc>496</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>state_child_flow4_new</name>
|
||||
<description/>
|
||||
<type>WRITE_TO_FILE</type>
|
||||
<attributes/>
|
||||
<appendFile>N</appendFile>
|
||||
<content>{
|
||||
"status": "NEW",
|
||||
"pipeline": "child_flow4"
|
||||
}</content>
|
||||
<createParentFolder>N</createParentFolder>
|
||||
<encoding>UTF-8</encoding>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow4.json</filename>
|
||||
<parallel>N</parallel>
|
||||
<xloc>848</xloc>
|
||||
<yloc>576</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>state_child_flow5_new</name>
|
||||
<description/>
|
||||
<type>WRITE_TO_FILE</type>
|
||||
<attributes/>
|
||||
<appendFile>N</appendFile>
|
||||
<content>{
|
||||
"status": "NEW",
|
||||
"pipeline": "child_flow5"
|
||||
}</content>
|
||||
<createParentFolder>N</createParentFolder>
|
||||
<encoding>UTF-8</encoding>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow5.json</filename>
|
||||
<parallel>N</parallel>
|
||||
<xloc>848</xloc>
|
||||
<yloc>656</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>Success</name>
|
||||
<description/>
|
||||
<type>SUCCESS</type>
|
||||
<attributes/>
|
||||
<parallel>N</parallel>
|
||||
<xloc>1120</xloc>
|
||||
<yloc>496</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>Delete file state_job_child</name>
|
||||
<description/>
|
||||
<type>DELETE_FILE</type>
|
||||
<attributes/>
|
||||
<fail_if_file_not_exists>N</fail_if_file_not_exists>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_job_child.json</filename>
|
||||
<parallel>N</parallel>
|
||||
<xloc>848</xloc>
|
||||
<yloc>256</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
</actions>
|
||||
<hops>
|
||||
<hop>
|
||||
<from>Start</from>
|
||||
<to>state_child_flow3_new</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>Y</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Start</from>
|
||||
<to>state_child_flow2_new</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>Y</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Start</from>
|
||||
<to>state_child_flow1_new</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>Y</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Start</from>
|
||||
<to>state_child_flow4_new</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>Y</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Start</from>
|
||||
<to>state_child_flow5_new</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>Y</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>state_child_flow5_new</from>
|
||||
<to>Success</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>N</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>state_child_flow4_new</from>
|
||||
<to>Success</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>N</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>state_child_flow3_new</from>
|
||||
<to>Success</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>N</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>state_child_flow2_new</from>
|
||||
<to>Success</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>N</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>state_child_flow1_new</from>
|
||||
<to>Success</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>N</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Start</from>
|
||||
<to>Delete file state_job_child</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>Y</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Delete file state_job_child</from>
|
||||
<to>Success</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>N</unconditional>
|
||||
</hop>
|
||||
</hops>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<attributes/>
|
||||
</workflow>
|
||||
File diff suppressed because it is too large
Load diff
|
|
@ -0,0 +1,595 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>child_flow</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/08/05 14:31:22.799</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/08/05 14:31:22.799</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Create job execution record </from>
|
||||
<to>Table input </to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>User defined Java expression 2</from>
|
||||
<to>Update 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update 2</from>
|
||||
<to>Change job status on error </to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Change job status on error </from>
|
||||
<to>Abort</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update 2</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Filter rows</from>
|
||||
<to>Change job status on success </to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update 2</from>
|
||||
<to>Detect empty stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Detect empty stream</from>
|
||||
<to>Change job status on success </to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input </from>
|
||||
<to>Table output</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Group by 2</from>
|
||||
<to>Identify last row in a stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Identify last row in a stream</from>
|
||||
<to>User defined Java expression 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table output</from>
|
||||
<to>Change job status on error </to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table output</from>
|
||||
<to>Group by 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Abort</name>
|
||||
<type>Abort</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<abort_option>ABORT_WITH_ERROR</abort_option>
|
||||
<always_log_rows>Y</always_log_rows>
|
||||
<row_threshold>0</row_threshold>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1216</xloc>
|
||||
<yloc>1024</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on error </name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
<argument>
|
||||
<name>error_description</name>
|
||||
</argument>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>Y</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET status = 'ERROR',
|
||||
error_description = ?
|
||||
WHERE job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1216</xloc>
|
||||
<yloc>800</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on success </name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>N</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET status = 'SUCCESS',
|
||||
error_description = null
|
||||
WHERE job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1744</xloc>
|
||||
<yloc>608</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Create job execution record </name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>N</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>INSERT INTO etl.job_execution (id, job_name, status, execution_datetime, error_description, recruitment_id)
|
||||
VALUES (DEFAULT, '${JOB_NAME}', 'PROCESSING', DEFAULT, null, '${IDM_ID}');
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>112</xloc>
|
||||
<yloc>800</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Detect empty stream</name>
|
||||
<type>DetectEmptyStream</type>
|
||||
<description/>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1568</xloc>
|
||||
<yloc>480</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Filter rows</name>
|
||||
<type>FilterRows</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compare>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>last_row</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>Y</text>
|
||||
<type>Boolean</type>
|
||||
</value>
|
||||
</condition>
|
||||
</compare>
|
||||
<send_true_to>Change job status on success </send_true_to>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1392</xloc>
|
||||
<yloc>608</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Group by 2</name>
|
||||
<type>GroupBy</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<add_linenr>N</add_linenr>
|
||||
<all_rows>N</all_rows>
|
||||
<directory>${java.io.tmpdir}</directory>
|
||||
<fields>
|
||||
<field>
|
||||
<aggregate>minors_count_raw</aggregate>
|
||||
<subject>is_minor</subject>
|
||||
<type>SUM</type>
|
||||
</field>
|
||||
<field>
|
||||
<aggregate>has_minor_child_raw</aggregate>
|
||||
<subject>is_minor</subject>
|
||||
<type>MAX</type>
|
||||
</field>
|
||||
<field>
|
||||
<aggregate>has_dead_child_raw</aggregate>
|
||||
<subject>is_dead</subject>
|
||||
<type>MAX</type>
|
||||
</field>
|
||||
</fields>
|
||||
<give_back_row>N</give_back_row>
|
||||
<group>
|
||||
<field>
|
||||
<name>recruit_id</name>
|
||||
</field>
|
||||
</group>
|
||||
<ignore_aggregate>N</ignore_aggregate>
|
||||
<prefix>grp</prefix>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>560</xloc>
|
||||
<yloc>480</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Identify last row in a stream</name>
|
||||
<type>DetectLastRow</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<resultfieldname>last_row</resultfieldname>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>480</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input </name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit/>
|
||||
<sql>SELECT
|
||||
ri.recruit_id AS recruit_id,
|
||||
(ch->>'id')::uuid AS child_external_id,
|
||||
NULLIF(ch->>'idERN', '') AS child_id_ern,
|
||||
CASE NULLIF(ch->>'rodstvSvyazReb', '')::int
|
||||
WHEN 1 THEN 3
|
||||
WHEN 2 THEN 4
|
||||
END AS kinship_type,
|
||||
ch->'svedFLBS'->'fio'->>'familiya' AS last_name,
|
||||
ch->'svedFLBS'->'fio'->>'imya' AS first_name,
|
||||
ch->'svedFLBS'->'fio'->>'otchestvo' AS middle_name,
|
||||
CONCAT_WS(' ',
|
||||
ch->'svedFLBS'->'fio'->>'familiya',
|
||||
ch->'svedFLBS'->'fio'->>'imya',
|
||||
ch->'svedFLBS'->'fio'->>'otchestvo'
|
||||
) AS full_name,
|
||||
dates.birth_date,
|
||||
dates.death_date,
|
||||
ch->'svedSmert'->>'nomerZapis' AS death_az_number,
|
||||
ch->'svedAZRozhd'->>'nomerZapis' AS birth_az_number,
|
||||
CASE WHEN dates.death_date IS NOT NULL THEN 1 ELSE 0 END AS is_dead,
|
||||
CASE
|
||||
WHEN dates.death_date IS NOT NULL THEN 0 -- умершие не могут быть несовершеннолетними
|
||||
WHEN dates.birth_date IS NULL THEN 0 -- если дата рождения неизвестна, считаем взрослым
|
||||
WHEN dates.birth_date > CURRENT_DATE - INTERVAL '18 years' THEN 1
|
||||
ELSE 0
|
||||
END AS is_minor
|
||||
FROM ervu_dashboard.recruits_info ri
|
||||
JOIN ervu_dashboard.citizen c ON c.recruit_id = ri.recruit_id
|
||||
CROSS JOIN LATERAL jsonb_array_elements(ri.info->'svedFL'->'svedDeti'->'rebenok') AS ch
|
||||
CROSS JOIN LATERAL (
|
||||
SELECT
|
||||
MAKE_DATE(
|
||||
NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'god', '')::int,
|
||||
NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'mesyacz', '')::int,
|
||||
NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'den', '')::int
|
||||
) AS birth_date,
|
||||
MAKE_DATE(
|
||||
NULLIF(ch->'svedSmert'->'dataSmert'->>'god', '')::int,
|
||||
NULLIF(ch->'svedSmert'->'dataSmert'->>'mesyacz', '')::int,
|
||||
NULLIF(ch->'svedSmert'->'dataSmert'->>'den', '')::int
|
||||
) AS death_date
|
||||
) AS dates
|
||||
WHERE
|
||||
'${IDM_ID}' != ''
|
||||
AND COALESCE(ri.current_recruitment_id, ri.target_recruitment_id) = '${IDM_ID}'
|
||||
AND'${M_R_CR_DATE}'::timestamp >= c.recruit_create_date
|
||||
AND jsonb_typeof(ri.info->'svedFL'->'svedDeti'->'rebenok') = 'array';</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>304</xloc>
|
||||
<yloc>800</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table output</name>
|
||||
<type>TableOutput</type>
|
||||
<description/>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>1000</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<fields>
|
||||
<field>
|
||||
<column_name>recruit_id</column_name>
|
||||
<stream_name>recruit_id</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>child_external_id</column_name>
|
||||
<stream_name>child_external_id</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>child_id_ern</column_name>
|
||||
<stream_name>child_id_ern</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>kinship_type</column_name>
|
||||
<stream_name>kinship_type</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>last_name</column_name>
|
||||
<stream_name>last_name</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>first_name</column_name>
|
||||
<stream_name>first_name</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>middle_name</column_name>
|
||||
<stream_name>middle_name</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>full_name</column_name>
|
||||
<stream_name>full_name</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>birth_date</column_name>
|
||||
<stream_name>birth_date</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>death_date</column_name>
|
||||
<stream_name>death_date</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>death_az_number</column_name>
|
||||
<stream_name>death_az_number</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>birth_az_number</column_name>
|
||||
<stream_name>birth_az_number</stream_name>
|
||||
</field>
|
||||
</fields>
|
||||
<ignore_errors>N</ignore_errors>
|
||||
<only_when_have_rows>N</only_when_have_rows>
|
||||
<partitioning_daily>N</partitioning_daily>
|
||||
<partitioning_enabled>N</partitioning_enabled>
|
||||
<partitioning_monthly>Y</partitioning_monthly>
|
||||
<return_keys>N</return_keys>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<specify_fields>Y</specify_fields>
|
||||
<table>citizen_child</table>
|
||||
<tablename_in_field>N</tablename_in_field>
|
||||
<tablename_in_table>Y</tablename_in_table>
|
||||
<truncate>N</truncate>
|
||||
<use_batch>Y</use_batch>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>560</xloc>
|
||||
<yloc>800</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Update 2</name>
|
||||
<type>Update</type>
|
||||
<description/>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<error_ignored>Y</error_ignored>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen</table>
|
||||
<value>
|
||||
<name>minors_count</name>
|
||||
<rename>minors_count</rename>
|
||||
</value>
|
||||
<value>
|
||||
<name>has_minor_child</name>
|
||||
<rename>has_minor_child</rename>
|
||||
</value>
|
||||
<value>
|
||||
<name>has_dead_child</name>
|
||||
<rename>has_dead_child</rename>
|
||||
</value>
|
||||
</lookup>
|
||||
<skip_lookup>N</skip_lookup>
|
||||
<use_batch>Y</use_batch>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1216</xloc>
|
||||
<yloc>480</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>User defined Java expression 2</name>
|
||||
<type>Janino</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<formula>
|
||||
<field_name>minors_count</field_name>
|
||||
<formula_string>minors_count_raw == 1 ? "1" : minors_count_raw == 2 ? "2" : minors_count_raw >= 3 ? "3 и более" : "0"</formula_string>
|
||||
<value_type>String</value_type>
|
||||
<value_length>10</value_length>
|
||||
<value_precision>-1</value_precision>
|
||||
<replace_field/>
|
||||
</formula>
|
||||
<formula>
|
||||
<field_name>has_minor_child</field_name>
|
||||
<formula_string>has_minor_child_raw == 1 </formula_string>
|
||||
<value_type>Boolean</value_type>
|
||||
<value_length>-1</value_length>
|
||||
<value_precision>-1</value_precision>
|
||||
<replace_field/>
|
||||
</formula>
|
||||
<formula>
|
||||
<field_name>has_dead_child</field_name>
|
||||
<formula_string>has_dead_child_raw == 1 </formula_string>
|
||||
<value_type>Boolean</value_type>
|
||||
<value_length>-1</value_length>
|
||||
<value_precision>-1</value_precision>
|
||||
<replace_field/>
|
||||
</formula>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1024</xloc>
|
||||
<yloc>480</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
<error>
|
||||
<source_transform>Create job execution record </source_transform>
|
||||
<target_transform>Change job status on error </target_transform>
|
||||
<is_enabled>N</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename/>
|
||||
<fields_valuename/>
|
||||
<codes_valuename/>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
<error>
|
||||
<source_transform>Table output</source_transform>
|
||||
<target_transform>Change job status on error </target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename>error_description</descriptions_valuename>
|
||||
<fields_valuename/>
|
||||
<codes_valuename>error_code</codes_valuename>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
<error>
|
||||
<source_transform>Update 2</source_transform>
|
||||
<target_transform>Change job status on error </target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename>error_description</descriptions_valuename>
|
||||
<fields_valuename/>
|
||||
<codes_valuename>error_code</codes_valuename>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,229 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>child_flow1</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<pipeline_status>0</pipeline_status>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/05/21 14:05:02.260</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/05/21 14:05:02.260</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Select values 4 2</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Select values 4 2</from>
|
||||
<to>Get variables</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Get variables</name>
|
||||
<type>GetVariable</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<fields>
|
||||
<field>
|
||||
<length>-1</length>
|
||||
<name>recruitment_id</name>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<type>String</type>
|
||||
<variable>ID_F1</variable>
|
||||
</field>
|
||||
</fields>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>976</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_child</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_az_number</name>
|
||||
<rename>birth_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_date</name>
|
||||
<rename>birth_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_az_number</name>
|
||||
<rename>death_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_date</name>
|
||||
<rename>death_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>full_name</name>
|
||||
<rename>full_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>kinship_type</name>
|
||||
<rename>kinship_type</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>944</xloc>
|
||||
<yloc>288</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Select values 4 2</name>
|
||||
<type>SelectValues</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<fields>
|
||||
<select_unspecified>N</select_unspecified>
|
||||
<meta>
|
||||
<name>ID_F1</name>
|
||||
<rename>ID_F1</rename>
|
||||
<type>String</type>
|
||||
<length>-2</length>
|
||||
<precision>-2</precision>
|
||||
<conversion_mask/>
|
||||
<date_format_lenient>false</date_format_lenient>
|
||||
<date_format_locale/>
|
||||
<date_format_timezone/>
|
||||
<lenient_string_to_number>false</lenient_string_to_number>
|
||||
<encoding/>
|
||||
<decimal_symbol/>
|
||||
<grouping_symbol/>
|
||||
<currency_symbol/>
|
||||
<storage_type/>
|
||||
</meta>
|
||||
</fields>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>720</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>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_F1}' != '' -- Проверка на пустую строку
|
||||
AND COALESCE(ri.current_recruitment_id, ri.target_recruitment_id) = '${ID_F1}'
|
||||
AND '${M_R_CR_DATE}'::timestamp >= ri.created_at
|
||||
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</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>448</xloc>
|
||||
<yloc>288</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
<error>
|
||||
<source_transform>Select values 4 2</source_transform>
|
||||
<target_transform>Get variables</target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename/>
|
||||
<fields_valuename/>
|
||||
<codes_valuename/>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,142 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>child_flow2</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/05/21 14:05:02.260</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/05/21 14:05:02.260</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_child</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_az_number</name>
|
||||
<rename>birth_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_date</name>
|
||||
<rename>birth_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_az_number</name>
|
||||
<rename>death_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_date</name>
|
||||
<rename>death_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>full_name</name>
|
||||
<rename>full_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>kinship_type</name>
|
||||
<rename>kinship_type</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1088</xloc>
|
||||
<yloc>288</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>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
|
||||
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</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>560</xloc>
|
||||
<yloc>288</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,142 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>child_flow3</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/05/21 14:05:02.260</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/05/21 14:05:02.260</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_child</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_az_number</name>
|
||||
<rename>birth_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_date</name>
|
||||
<rename>birth_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_az_number</name>
|
||||
<rename>death_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_date</name>
|
||||
<rename>death_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>full_name</name>
|
||||
<rename>full_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>kinship_type</name>
|
||||
<rename>kinship_type</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1216</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>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
|
||||
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</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>672</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,142 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>child_flow4</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/05/21 14:05:02.260</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/05/21 14:05:02.260</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_child</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_az_number</name>
|
||||
<rename>birth_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_date</name>
|
||||
<rename>birth_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_az_number</name>
|
||||
<rename>death_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_date</name>
|
||||
<rename>death_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>full_name</name>
|
||||
<rename>full_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>kinship_type</name>
|
||||
<rename>kinship_type</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1072</xloc>
|
||||
<yloc>320</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>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
|
||||
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</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>528</xloc>
|
||||
<yloc>320</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,142 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>child_flow5</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/05/21 14:05:02.260</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/05/21 14:05:02.260</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_child</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_az_number</name>
|
||||
<rename>birth_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_date</name>
|
||||
<rename>birth_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_az_number</name>
|
||||
<rename>death_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_date</name>
|
||||
<rename>death_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>full_name</name>
|
||||
<rename>full_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>kinship_type</name>
|
||||
<rename>kinship_type</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1040</xloc>
|
||||
<yloc>368</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>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
|
||||
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</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>560</xloc>
|
||||
<yloc>368</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -0,0 +1,598 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>child_flow_delta</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/08/11 13:22:56.048</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/08/11 13:22:56.048</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Insert / update</from>
|
||||
<to>Change job status on error </to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Insert / update</from>
|
||||
<to>Group by</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update </from>
|
||||
<to>Change job status on error </to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>User defined Java expression</from>
|
||||
<to>Update </to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Create job execution record</from>
|
||||
<to>Table input 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update </from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Filter rows</from>
|
||||
<to>Change job status on success </to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update </from>
|
||||
<to>Detect empty stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Detect empty stream</from>
|
||||
<to>Change job status on success </to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Change job status on error </from>
|
||||
<to>Abort</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Group by</from>
|
||||
<to>Identify last row in a stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Identify last row in a stream</from>
|
||||
<to>User defined Java expression</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input 2</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Abort</name>
|
||||
<type>Abort</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<abort_option>ABORT_WITH_ERROR</abort_option>
|
||||
<always_log_rows>Y</always_log_rows>
|
||||
<row_threshold>0</row_threshold>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1376</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on error </name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
<argument>
|
||||
<name>error_description</name>
|
||||
</argument>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>N</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET status = 'DELTA_ERROR',
|
||||
error_description = ?
|
||||
WHERE job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1376</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on success </name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>N</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET status = 'DELTA_SUCCESS',
|
||||
error_description = null
|
||||
WHERE job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}'
|
||||
and status = 'DELTA_PROCESSING';
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1872</xloc>
|
||||
<yloc>0</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Create job execution record</name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>N</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET
|
||||
status = 'DELTA_PROCESSING',
|
||||
execution_datetime = DEFAULT
|
||||
where job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>288</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Detect empty stream</name>
|
||||
<type>DetectEmptyStream</type>
|
||||
<description/>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1616</xloc>
|
||||
<yloc>144</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Filter rows</name>
|
||||
<type>FilterRows</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compare>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>last_row</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>Y</text>
|
||||
<type>Boolean</type>
|
||||
</value>
|
||||
</condition>
|
||||
</compare>
|
||||
<send_true_to>Change job status on success </send_true_to>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1616</xloc>
|
||||
<yloc>0</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Group by</name>
|
||||
<type>GroupBy</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<add_linenr>N</add_linenr>
|
||||
<all_rows>N</all_rows>
|
||||
<directory>${java.io.tmpdir}</directory>
|
||||
<fields>
|
||||
<field>
|
||||
<aggregate>minors_count_raw</aggregate>
|
||||
<subject>is_minor</subject>
|
||||
<type>SUM</type>
|
||||
</field>
|
||||
<field>
|
||||
<aggregate>has_minor_child_raw</aggregate>
|
||||
<subject>is_minor</subject>
|
||||
<type>MAX</type>
|
||||
</field>
|
||||
<field>
|
||||
<aggregate>has_dead_child_raw</aggregate>
|
||||
<subject>is_dead</subject>
|
||||
<type>MAX</type>
|
||||
</field>
|
||||
</fields>
|
||||
<give_back_row>N</give_back_row>
|
||||
<group>
|
||||
<field>
|
||||
<name>recruit_id</name>
|
||||
</field>
|
||||
</group>
|
||||
<ignore_aggregate>N</ignore_aggregate>
|
||||
<prefix>grp</prefix>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>0</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Identify last row in a stream</name>
|
||||
<type>DetectLastRow</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<resultfieldname>last_row</resultfieldname>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1024</xloc>
|
||||
<yloc>0</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>child_external_id</field>
|
||||
<name>child_external_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_child</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_az_number</name>
|
||||
<rename>birth_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_date</name>
|
||||
<rename>birth_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_az_number</name>
|
||||
<rename>death_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_date</name>
|
||||
<rename>death_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>full_name</name>
|
||||
<rename>full_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>kinship_type</name>
|
||||
<rename>kinship_type</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>child_external_id</name>
|
||||
<rename>child_external_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>first_name</name>
|
||||
<rename>first_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>middle_name</name>
|
||||
<rename>middle_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_name</name>
|
||||
<rename>last_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>child_id_ern</name>
|
||||
<rename>child_id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input 2</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit/>
|
||||
<sql>SELECT
|
||||
ri.recruit_id AS recruit_id,
|
||||
(ch->>'id')::uuid AS child_external_id,
|
||||
NULLIF(ch->>'idERN', '') AS child_id_ern,
|
||||
CASE NULLIF(ch->>'rodstvSvyazReb', '')::int
|
||||
WHEN 1 THEN 3
|
||||
WHEN 2 THEN 4
|
||||
END AS kinship_type,
|
||||
ch->'svedFLBS'->'fio'->>'familiya' AS last_name,
|
||||
ch->'svedFLBS'->'fio'->>'imya' AS first_name,
|
||||
ch->'svedFLBS'->'fio'->>'otchestvo' AS middle_name,
|
||||
CONCAT_WS(' ',
|
||||
ch->'svedFLBS'->'fio'->>'familiya',
|
||||
ch->'svedFLBS'->'fio'->>'imya',
|
||||
ch->'svedFLBS'->'fio'->>'otchestvo'
|
||||
) AS full_name,
|
||||
dates.birth_date,
|
||||
dates.death_date,
|
||||
ch->'svedSmert'->>'nomerZapis' AS death_az_number,
|
||||
ch->'svedAZRozhd'->>'nomerZapis' AS birth_az_number,
|
||||
CASE WHEN dates.death_date IS NOT NULL THEN 1 ELSE 0 END AS is_dead,
|
||||
CASE
|
||||
WHEN dates.death_date IS NOT NULL THEN 0 -- умершие не могут быть несовершеннолетними
|
||||
WHEN dates.birth_date IS NULL THEN 0 -- если дата рождения неизвестна, считаем взрослым
|
||||
WHEN dates.birth_date > CURRENT_DATE - INTERVAL '18 years' THEN 1
|
||||
ELSE 0
|
||||
END AS is_minor
|
||||
FROM ervu_dashboard.recruits_info ri
|
||||
JOIN ervu_dashboard.citizen c ON c.recruit_id = ri.recruit_id
|
||||
CROSS JOIN LATERAL jsonb_array_elements(ri.info->'svedFL'->'svedDeti'->'rebenok') AS ch
|
||||
CROSS JOIN LATERAL (
|
||||
SELECT
|
||||
MAKE_DATE(
|
||||
NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'god', '')::int,
|
||||
NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'mesyacz', '')::int,
|
||||
NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'den', '')::int
|
||||
) AS birth_date,
|
||||
MAKE_DATE(
|
||||
NULLIF(ch->'svedSmert'->'dataSmert'->>'god', '')::int,
|
||||
NULLIF(ch->'svedSmert'->'dataSmert'->>'mesyacz', '')::int,
|
||||
NULLIF(ch->'svedSmert'->'dataSmert'->>'den', '')::int
|
||||
) AS death_date
|
||||
) AS dates
|
||||
WHERE
|
||||
'${IDM_ID}' != ''
|
||||
AND COALESCE(ri.current_recruitment_id, ri.target_recruitment_id) = '${IDM_ID}'
|
||||
AND'${M_R_CR_DATE}'::timestamp >= c.recruit_create_date
|
||||
AND c.update_date >= '${M_R_UP_DATE}'::timestamp
|
||||
AND jsonb_typeof(ri.info->'svedFL'->'svedDeti'->'rebenok') = 'array';</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>496</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Update </name>
|
||||
<type>Update</type>
|
||||
<description/>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<error_ignored>Y</error_ignored>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen</table>
|
||||
<value>
|
||||
<name>minors_count</name>
|
||||
<rename>minors_count</rename>
|
||||
</value>
|
||||
<value>
|
||||
<name>has_minor_child</name>
|
||||
<rename>has_minor_child</rename>
|
||||
</value>
|
||||
<value>
|
||||
<name>has_dead_child</name>
|
||||
<rename>has_dead_child</rename>
|
||||
</value>
|
||||
</lookup>
|
||||
<skip_lookup>N</skip_lookup>
|
||||
<use_batch>Y</use_batch>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1376</xloc>
|
||||
<yloc>0</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>User defined Java expression</name>
|
||||
<type>Janino</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<formula>
|
||||
<field_name>minors_count</field_name>
|
||||
<formula_string>minors_count_raw == 1 ? "1" : minors_count_raw == 2 ? "2" : minors_count_raw >= 3 ? "3 и более" : "0"</formula_string>
|
||||
<value_type>String</value_type>
|
||||
<value_length>10</value_length>
|
||||
<value_precision>-1</value_precision>
|
||||
<replace_field/>
|
||||
</formula>
|
||||
<formula>
|
||||
<field_name>has_minor_child</field_name>
|
||||
<formula_string>has_minor_child_raw == 1 </formula_string>
|
||||
<value_type>Boolean</value_type>
|
||||
<value_length>-1</value_length>
|
||||
<value_precision>-1</value_precision>
|
||||
<replace_field/>
|
||||
</formula>
|
||||
<formula>
|
||||
<field_name>has_dead_child</field_name>
|
||||
<formula_string>has_dead_child_raw == 1 </formula_string>
|
||||
<value_type>Boolean</value_type>
|
||||
<value_length>-1</value_length>
|
||||
<value_precision>-1</value_precision>
|
||||
<replace_field/>
|
||||
</formula>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1232</xloc>
|
||||
<yloc>0</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
<error>
|
||||
<source_transform>Insert / update</source_transform>
|
||||
<target_transform>Change job status on error </target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename>error_description</descriptions_valuename>
|
||||
<fields_valuename/>
|
||||
<codes_valuename>error_code</codes_valuename>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
<error>
|
||||
<source_transform>Update </source_transform>
|
||||
<target_transform>Change job status on error </target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename>error_description</descriptions_valuename>
|
||||
<fields_valuename/>
|
||||
<codes_valuename>error_code</codes_valuename>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -0,0 +1,613 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>child_flow_repeat</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/08/08 13:25:52.319</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/08/08 13:25:52.319</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>User defined Java expression</from>
|
||||
<to>Update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Create job execution record 2</from>
|
||||
<to>Table input 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update</from>
|
||||
<to>Change job status on error 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Insert / update</from>
|
||||
<to>Change job status on error 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Insert / update</from>
|
||||
<to>Group by</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update</from>
|
||||
<to>Detect empty stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Detect empty stream</from>
|
||||
<to>Change job status on success</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Filter rows</from>
|
||||
<to>Change job status on success</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Change job status on error 2</from>
|
||||
<to>Abort</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Group by</from>
|
||||
<to>Identify last row in a stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Identify last row in a stream</from>
|
||||
<to>User defined Java expression</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input 2</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Abort</name>
|
||||
<type>Abort</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<abort_option>ABORT_WITH_ERROR</abort_option>
|
||||
<always_log_rows>Y</always_log_rows>
|
||||
<row_threshold>0</row_threshold>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>976</xloc>
|
||||
<yloc>608</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on error 2</name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
<argument>
|
||||
<name>error_description</name>
|
||||
</argument>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>Y</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET status = 'ERROR',
|
||||
error_description = ?
|
||||
WHERE job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>976</xloc>
|
||||
<yloc>432</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on success</name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>N</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET status = 'SUCCESS',
|
||||
error_description = null
|
||||
WHERE job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}'
|
||||
and status = 'PROCESSING';
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1440</xloc>
|
||||
<yloc>0</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Create job execution record 2</name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>N</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>INSERT INTO etl.job_execution (
|
||||
id,
|
||||
job_name,
|
||||
status,
|
||||
execution_datetime,
|
||||
error_description,
|
||||
recruitment_id
|
||||
)
|
||||
VALUES (
|
||||
DEFAULT,
|
||||
'${JOB_NAME}',
|
||||
'PROCESSING',
|
||||
DEFAULT,
|
||||
NULL,
|
||||
'${IDM_ID}'
|
||||
)
|
||||
ON CONFLICT (job_name, recruitment_id)
|
||||
DO UPDATE SET
|
||||
status = 'PROCESSING',
|
||||
execution_datetime = DEFAULT,
|
||||
error_description = NULL;</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>0</xloc>
|
||||
<yloc>432</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Detect empty stream</name>
|
||||
<type>DetectEmptyStream</type>
|
||||
<description/>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1216</xloc>
|
||||
<yloc>0</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Filter rows</name>
|
||||
<type>FilterRows</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compare>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>last_row</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>Y</text>
|
||||
<type>Boolean</type>
|
||||
</value>
|
||||
</condition>
|
||||
</compare>
|
||||
<send_true_to>Change job status on success</send_true_to>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1216</xloc>
|
||||
<yloc>128</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Group by</name>
|
||||
<type>GroupBy</type>
|
||||
<description/>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<add_linenr>N</add_linenr>
|
||||
<all_rows>N</all_rows>
|
||||
<directory>${java.io.tmpdir}</directory>
|
||||
<fields>
|
||||
<field>
|
||||
<aggregate>minors_count_raw</aggregate>
|
||||
<subject>is_minor</subject>
|
||||
<type>SUM</type>
|
||||
</field>
|
||||
<field>
|
||||
<aggregate>has_minor_child_raw</aggregate>
|
||||
<subject>is_minor</subject>
|
||||
<type>MAX</type>
|
||||
</field>
|
||||
<field>
|
||||
<aggregate>has_dead_child_raw</aggregate>
|
||||
<subject>is_dead</subject>
|
||||
<type>MAX</type>
|
||||
</field>
|
||||
</fields>
|
||||
<give_back_row>N</give_back_row>
|
||||
<group>
|
||||
<field>
|
||||
<name>recruit_id</name>
|
||||
</field>
|
||||
</group>
|
||||
<ignore_aggregate>N</ignore_aggregate>
|
||||
<prefix>grp</prefix>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>608</xloc>
|
||||
<yloc>192</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Identify last row in a stream</name>
|
||||
<type>DetectLastRow</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<resultfieldname>last_row</resultfieldname>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>608</xloc>
|
||||
<yloc>0</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>child_external_id</field>
|
||||
<name>child_external_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_child</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_az_number</name>
|
||||
<rename>birth_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_date</name>
|
||||
<rename>birth_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_az_number</name>
|
||||
<rename>death_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_date</name>
|
||||
<rename>death_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>full_name</name>
|
||||
<rename>full_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>kinship_type</name>
|
||||
<rename>kinship_type</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>child_external_id</name>
|
||||
<rename>child_external_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>first_name</name>
|
||||
<rename>first_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>middle_name</name>
|
||||
<rename>middle_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_name</name>
|
||||
<rename>last_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>child_id_ern</name>
|
||||
<rename>child_id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>608</xloc>
|
||||
<yloc>432</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input 2</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit/>
|
||||
<sql>SELECT
|
||||
ri.recruit_id AS recruit_id,
|
||||
(ch->>'id')::uuid AS child_external_id,
|
||||
NULLIF(ch->>'idERN', '') AS child_id_ern,
|
||||
CASE NULLIF(ch->>'rodstvSvyazReb', '')::int
|
||||
WHEN 1 THEN 3
|
||||
WHEN 2 THEN 4
|
||||
END AS kinship_type,
|
||||
ch->'svedFLBS'->'fio'->>'familiya' AS last_name,
|
||||
ch->'svedFLBS'->'fio'->>'imya' AS first_name,
|
||||
ch->'svedFLBS'->'fio'->>'otchestvo' AS middle_name,
|
||||
CONCAT_WS(' ',
|
||||
ch->'svedFLBS'->'fio'->>'familiya',
|
||||
ch->'svedFLBS'->'fio'->>'imya',
|
||||
ch->'svedFLBS'->'fio'->>'otchestvo'
|
||||
) AS full_name,
|
||||
dates.birth_date,
|
||||
dates.death_date,
|
||||
ch->'svedSmert'->>'nomerZapis' AS death_az_number,
|
||||
ch->'svedAZRozhd'->>'nomerZapis' AS birth_az_number,
|
||||
CASE WHEN dates.death_date IS NOT NULL THEN 1 ELSE 0 END AS is_dead,
|
||||
CASE
|
||||
WHEN dates.death_date IS NOT NULL THEN 0 -- умершие не могут быть несовершеннолетними
|
||||
WHEN dates.birth_date IS NULL THEN 0 -- если дата рождения неизвестна, считаем взрослым
|
||||
WHEN dates.birth_date > CURRENT_DATE - INTERVAL '18 years' THEN 1
|
||||
ELSE 0
|
||||
END AS is_minor
|
||||
FROM ervu_dashboard.recruits_info ri
|
||||
JOIN ervu_dashboard.citizen c ON c.recruit_id = ri.recruit_id
|
||||
CROSS JOIN LATERAL jsonb_array_elements(ri.info->'svedFL'->'svedDeti'->'rebenok') AS ch
|
||||
CROSS JOIN LATERAL (
|
||||
SELECT
|
||||
MAKE_DATE(
|
||||
NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'god', '')::int,
|
||||
NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'mesyacz', '')::int,
|
||||
NULLIF(ch->'svedFLBS'->'dataRozhdDok'->>'den', '')::int
|
||||
) AS birth_date,
|
||||
MAKE_DATE(
|
||||
NULLIF(ch->'svedSmert'->'dataSmert'->>'god', '')::int,
|
||||
NULLIF(ch->'svedSmert'->'dataSmert'->>'mesyacz', '')::int,
|
||||
NULLIF(ch->'svedSmert'->'dataSmert'->>'den', '')::int
|
||||
) AS death_date
|
||||
) AS dates
|
||||
WHERE
|
||||
'${IDM_ID}' != ''
|
||||
AND COALESCE(ri.current_recruitment_id, ri.target_recruitment_id) = '${IDM_ID}'
|
||||
AND'${M_R_CR_DATE}'::timestamp >= c.recruit_create_date
|
||||
AND jsonb_typeof(ri.info->'svedFL'->'svedDeti'->'rebenok') = 'array';</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>272</xloc>
|
||||
<yloc>432</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Update</name>
|
||||
<type>Update</type>
|
||||
<description/>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<error_ignored>Y</error_ignored>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen</table>
|
||||
<value>
|
||||
<name>minors_count</name>
|
||||
<rename>minors_count</rename>
|
||||
</value>
|
||||
<value>
|
||||
<name>has_minor_child</name>
|
||||
<rename>has_minor_child</rename>
|
||||
</value>
|
||||
<value>
|
||||
<name>has_dead_child</name>
|
||||
<rename>has_dead_child</rename>
|
||||
</value>
|
||||
</lookup>
|
||||
<skip_lookup>N</skip_lookup>
|
||||
<use_batch>Y</use_batch>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>976</xloc>
|
||||
<yloc>0</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>User defined Java expression</name>
|
||||
<type>Janino</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<formula>
|
||||
<field_name>minors_count</field_name>
|
||||
<formula_string>minors_count_raw == 1 ? "1" : minors_count_raw == 2 ? "2" : minors_count_raw >= 3 ? "3 и более" : "0"</formula_string>
|
||||
<value_type>String</value_type>
|
||||
<value_length>10</value_length>
|
||||
<value_precision>-1</value_precision>
|
||||
<replace_field/>
|
||||
</formula>
|
||||
<formula>
|
||||
<field_name>has_minor_child</field_name>
|
||||
<formula_string>has_minor_child_raw == 1 </formula_string>
|
||||
<value_type>Boolean</value_type>
|
||||
<value_length>-1</value_length>
|
||||
<value_precision>-1</value_precision>
|
||||
<replace_field/>
|
||||
</formula>
|
||||
<formula>
|
||||
<field_name>has_dead_child</field_name>
|
||||
<formula_string>has_dead_child_raw == 1 </formula_string>
|
||||
<value_type>Boolean</value_type>
|
||||
<value_length>-1</value_length>
|
||||
<value_precision>-1</value_precision>
|
||||
<replace_field/>
|
||||
</formula>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>800</xloc>
|
||||
<yloc>0</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
<error>
|
||||
<source_transform>Insert / update</source_transform>
|
||||
<target_transform>Change job status on error 2</target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename/>
|
||||
<fields_valuename/>
|
||||
<codes_valuename/>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
<error>
|
||||
<source_transform>Update</source_transform>
|
||||
<target_transform>Change job status on error 2</target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename>error_description</descriptions_valuename>
|
||||
<fields_valuename/>
|
||||
<codes_valuename>error_code</codes_valuename>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,143 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>delta_child_flow1</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/03 16:10:48.509</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/03 16:10:48.509</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_child</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_az_number</name>
|
||||
<rename>birth_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_date</name>
|
||||
<rename>birth_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_az_number</name>
|
||||
<rename>death_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_date</name>
|
||||
<rename>death_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>full_name</name>
|
||||
<rename>full_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>kinship_type</name>
|
||||
<rename>kinship_type</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1168</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>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_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'
|
||||
)
|
||||
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</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>624</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,143 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>delta_child_flow2</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/03 16:10:48.509</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/03 16:10:48.509</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_child</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_az_number</name>
|
||||
<rename>birth_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_date</name>
|
||||
<rename>birth_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_az_number</name>
|
||||
<rename>death_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_date</name>
|
||||
<rename>death_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>full_name</name>
|
||||
<rename>full_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>kinship_type</name>
|
||||
<rename>kinship_type</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1168</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>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</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>624</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,143 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>delta_child_flow3</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/03 16:10:48.509</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/03 16:10:48.509</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_child</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_az_number</name>
|
||||
<rename>birth_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_date</name>
|
||||
<rename>birth_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_az_number</name>
|
||||
<rename>death_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_date</name>
|
||||
<rename>death_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>full_name</name>
|
||||
<rename>full_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>kinship_type</name>
|
||||
<rename>kinship_type</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1168</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>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</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>624</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,143 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>delta_child_flow4</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/03 16:10:48.509</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/03 16:10:48.509</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_child</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_az_number</name>
|
||||
<rename>birth_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_date</name>
|
||||
<rename>birth_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_az_number</name>
|
||||
<rename>death_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_date</name>
|
||||
<rename>death_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>full_name</name>
|
||||
<rename>full_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>kinship_type</name>
|
||||
<rename>kinship_type</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1168</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>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</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>624</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,143 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>delta_child_flow5</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/03 16:10:48.509</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/03 16:10:48.509</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_child</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_az_number</name>
|
||||
<rename>birth_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_date</name>
|
||||
<rename>birth_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_az_number</name>
|
||||
<rename>death_az_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>death_date</name>
|
||||
<rename>death_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>full_name</name>
|
||||
<rename>full_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>kinship_type</name>
|
||||
<rename>kinship_type</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1168</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>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</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>624</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -22,27 +22,27 @@
|
|||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>work_activity_flow_delta.hpl</to>
|
||||
<to>child_flow_delta.hpl</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>work_activity_flow_delta.hpl 2</to>
|
||||
<to>child_flow_delta.hpl 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>work_activity_flow_delta.hpl 3</to>
|
||||
<to>child_flow_delta.hpl 3</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>work_activity_flow_delta.hpl 4</to>
|
||||
<to>child_flow_delta.hpl 4</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>work_activity_flow_delta.hpl 5</to>
|
||||
<to>child_flow_delta.hpl 5</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
|
|
@ -63,9 +63,9 @@
|
|||
<sql>SELECT
|
||||
r.idm_id as recruitment_id
|
||||
FROM ervu_dashboard.recruitment r
|
||||
LEFT JOIN public.job_execution je
|
||||
LEFT JOIN etl.job_execution je
|
||||
ON r.idm_id = je.recruitment_id
|
||||
and job_name = 'work_activity_job'
|
||||
and job_name = 'child_job'
|
||||
where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING');</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
|
|
@ -75,7 +75,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>work_activity_flow_delta.hpl</name>
|
||||
<name>child_flow_delta.hpl</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
|
|
@ -86,7 +86,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/work_activity/parallel/work_activity_flow_delta.hpl</filename>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow_delta.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
|
|
@ -101,7 +101,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>work_activity_job</input>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
|
|
@ -131,7 +131,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>work_activity_flow_delta.hpl 2</name>
|
||||
<name>child_flow_delta.hpl 2</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
|
|
@ -142,7 +142,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/work_activity/parallel/work_activity_flow_delta.hpl</filename>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow_delta.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
|
|
@ -157,7 +157,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>work_activity_job</input>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
|
|
@ -187,7 +187,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>work_activity_flow_delta.hpl 3</name>
|
||||
<name>child_flow_delta.hpl 3</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
|
|
@ -198,7 +198,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/work_activity/parallel/work_activity_flow_delta.hpl</filename>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow_delta.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
|
|
@ -213,7 +213,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>work_activity_job</input>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
|
|
@ -243,7 +243,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>work_activity_flow_delta.hpl 4</name>
|
||||
<name>child_flow_delta.hpl 4</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
|
|
@ -254,7 +254,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/work_activity/parallel/work_activity_flow_delta.hpl</filename>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow_delta.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
|
|
@ -269,7 +269,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>work_activity_job</input>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
|
|
@ -299,7 +299,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>work_activity_flow_delta.hpl 5</name>
|
||||
<name>child_flow_delta.hpl 5</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
|
|
@ -310,7 +310,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/work_activity/parallel/work_activity_flow_delta.hpl</filename>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow_delta.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
|
|
@ -325,7 +325,7 @@ where je.status in ('SUCCESS', 'DELTA_ERROR', 'DELTA_SUCCESS', 'DELTA_PROCESSING
|
|||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>work_activity_job</input>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
|
|
@ -0,0 +1,360 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>recruitment_five_flow_on_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/08/05 12:54:50.126</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/08/05 12:54:50.126</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>child_flow_repeat.hpl</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>child_flow_repeat.hpl 3</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>child_flow_repeat.hpl 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>child_flow_repeat.hpl 4</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>child_flow_repeat.hpl 5</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit/>
|
||||
<sql>SELECT
|
||||
r.idm_id as recruitment_id
|
||||
FROM ervu_dashboard.recruitment r
|
||||
LEFT JOIN etl.job_execution je
|
||||
ON r.idm_id = je.recruitment_id
|
||||
and job_name = 'child_job'
|
||||
where je.status is null or je.status in('ERROR', 'PROCESSING');</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>272</xloc>
|
||||
<yloc>368</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>child_flow_repeat.hpl</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow_repeat.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
<group_field/>
|
||||
<group_time/>
|
||||
<parameters>
|
||||
<variable_mapping>
|
||||
<variable>IDM_ID</variable>
|
||||
<field>recruitment_id</field>
|
||||
<input/>
|
||||
</variable_mapping>
|
||||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
<execution_result_target_transform/>
|
||||
<execution_time_field>ExecutionTime</execution_time_field>
|
||||
<execution_result_field>ExecutionResult</execution_result_field>
|
||||
<execution_errors_field>ExecutionNrErrors</execution_errors_field>
|
||||
<execution_lines_read_field>ExecutionLinesRead</execution_lines_read_field>
|
||||
<execution_lines_written_field>ExecutionLinesWritten</execution_lines_written_field>
|
||||
<execution_lines_input_field>ExecutionLinesInput</execution_lines_input_field>
|
||||
<execution_lines_output_field>ExecutionLinesOutput</execution_lines_output_field>
|
||||
<execution_lines_rejected_field>ExecutionLinesRejected</execution_lines_rejected_field>
|
||||
<execution_lines_updated_field>ExecutionLinesUpdated</execution_lines_updated_field>
|
||||
<execution_lines_deleted_field>ExecutionLinesDeleted</execution_lines_deleted_field>
|
||||
<execution_files_retrieved_field>ExecutionFilesRetrieved</execution_files_retrieved_field>
|
||||
<execution_exit_status_field>ExecutionExitStatus</execution_exit_status_field>
|
||||
<execution_log_text_field>ExecutionLogText</execution_log_text_field>
|
||||
<execution_log_channelid_field>ExecutionLogChannelId</execution_log_channelid_field>
|
||||
<result_rows_target_transform/>
|
||||
<result_files_target_transform/>
|
||||
<result_files_file_name_field>FileName</result_files_file_name_field>
|
||||
<executors_output_transform/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>464</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>child_flow_repeat.hpl 2</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow_repeat.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
<group_field/>
|
||||
<group_time/>
|
||||
<parameters>
|
||||
<variable_mapping>
|
||||
<variable>IDM_ID</variable>
|
||||
<field>recruitment_id</field>
|
||||
<input/>
|
||||
</variable_mapping>
|
||||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
<execution_result_target_transform/>
|
||||
<execution_time_field>ExecutionTime</execution_time_field>
|
||||
<execution_result_field>ExecutionResult</execution_result_field>
|
||||
<execution_errors_field>ExecutionNrErrors</execution_errors_field>
|
||||
<execution_lines_read_field>ExecutionLinesRead</execution_lines_read_field>
|
||||
<execution_lines_written_field>ExecutionLinesWritten</execution_lines_written_field>
|
||||
<execution_lines_input_field>ExecutionLinesInput</execution_lines_input_field>
|
||||
<execution_lines_output_field>ExecutionLinesOutput</execution_lines_output_field>
|
||||
<execution_lines_rejected_field>ExecutionLinesRejected</execution_lines_rejected_field>
|
||||
<execution_lines_updated_field>ExecutionLinesUpdated</execution_lines_updated_field>
|
||||
<execution_lines_deleted_field>ExecutionLinesDeleted</execution_lines_deleted_field>
|
||||
<execution_files_retrieved_field>ExecutionFilesRetrieved</execution_files_retrieved_field>
|
||||
<execution_exit_status_field>ExecutionExitStatus</execution_exit_status_field>
|
||||
<execution_log_text_field>ExecutionLogText</execution_log_text_field>
|
||||
<execution_log_channelid_field>ExecutionLogChannelId</execution_log_channelid_field>
|
||||
<result_rows_target_transform/>
|
||||
<result_files_target_transform/>
|
||||
<result_files_file_name_field>FileName</result_files_file_name_field>
|
||||
<executors_output_transform/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>464</xloc>
|
||||
<yloc>288</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>child_flow_repeat.hpl 3</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow_repeat.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
<group_field/>
|
||||
<group_time/>
|
||||
<parameters>
|
||||
<variable_mapping>
|
||||
<variable>IDM_ID</variable>
|
||||
<field>recruitment_id</field>
|
||||
<input/>
|
||||
</variable_mapping>
|
||||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
<execution_result_target_transform/>
|
||||
<execution_time_field>ExecutionTime</execution_time_field>
|
||||
<execution_result_field>ExecutionResult</execution_result_field>
|
||||
<execution_errors_field>ExecutionNrErrors</execution_errors_field>
|
||||
<execution_lines_read_field>ExecutionLinesRead</execution_lines_read_field>
|
||||
<execution_lines_written_field>ExecutionLinesWritten</execution_lines_written_field>
|
||||
<execution_lines_input_field>ExecutionLinesInput</execution_lines_input_field>
|
||||
<execution_lines_output_field>ExecutionLinesOutput</execution_lines_output_field>
|
||||
<execution_lines_rejected_field>ExecutionLinesRejected</execution_lines_rejected_field>
|
||||
<execution_lines_updated_field>ExecutionLinesUpdated</execution_lines_updated_field>
|
||||
<execution_lines_deleted_field>ExecutionLinesDeleted</execution_lines_deleted_field>
|
||||
<execution_files_retrieved_field>ExecutionFilesRetrieved</execution_files_retrieved_field>
|
||||
<execution_exit_status_field>ExecutionExitStatus</execution_exit_status_field>
|
||||
<execution_log_text_field>ExecutionLogText</execution_log_text_field>
|
||||
<execution_log_channelid_field>ExecutionLogChannelId</execution_log_channelid_field>
|
||||
<result_rows_target_transform/>
|
||||
<result_files_target_transform/>
|
||||
<result_files_file_name_field>FileName</result_files_file_name_field>
|
||||
<executors_output_transform/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>464</xloc>
|
||||
<yloc>368</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>child_flow_repeat.hpl 4</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow_repeat.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
<group_field/>
|
||||
<group_time/>
|
||||
<parameters>
|
||||
<variable_mapping>
|
||||
<variable>IDM_ID</variable>
|
||||
<field>recruitment_id</field>
|
||||
<input/>
|
||||
</variable_mapping>
|
||||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
<execution_result_target_transform/>
|
||||
<execution_time_field>ExecutionTime</execution_time_field>
|
||||
<execution_result_field>ExecutionResult</execution_result_field>
|
||||
<execution_errors_field>ExecutionNrErrors</execution_errors_field>
|
||||
<execution_lines_read_field>ExecutionLinesRead</execution_lines_read_field>
|
||||
<execution_lines_written_field>ExecutionLinesWritten</execution_lines_written_field>
|
||||
<execution_lines_input_field>ExecutionLinesInput</execution_lines_input_field>
|
||||
<execution_lines_output_field>ExecutionLinesOutput</execution_lines_output_field>
|
||||
<execution_lines_rejected_field>ExecutionLinesRejected</execution_lines_rejected_field>
|
||||
<execution_lines_updated_field>ExecutionLinesUpdated</execution_lines_updated_field>
|
||||
<execution_lines_deleted_field>ExecutionLinesDeleted</execution_lines_deleted_field>
|
||||
<execution_files_retrieved_field>ExecutionFilesRetrieved</execution_files_retrieved_field>
|
||||
<execution_exit_status_field>ExecutionExitStatus</execution_exit_status_field>
|
||||
<execution_log_text_field>ExecutionLogText</execution_log_text_field>
|
||||
<execution_log_channelid_field>ExecutionLogChannelId</execution_log_channelid_field>
|
||||
<result_rows_target_transform/>
|
||||
<result_files_target_transform/>
|
||||
<result_files_file_name_field>FileName</result_files_file_name_field>
|
||||
<executors_output_transform/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>464</xloc>
|
||||
<yloc>448</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>child_flow_repeat.hpl 5</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow_repeat.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
<group_field/>
|
||||
<group_time/>
|
||||
<parameters>
|
||||
<variable_mapping>
|
||||
<variable>IDM_ID</variable>
|
||||
<field>recruitment_id</field>
|
||||
<input/>
|
||||
</variable_mapping>
|
||||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
<execution_result_target_transform/>
|
||||
<execution_time_field>ExecutionTime</execution_time_field>
|
||||
<execution_result_field>ExecutionResult</execution_result_field>
|
||||
<execution_errors_field>ExecutionNrErrors</execution_errors_field>
|
||||
<execution_lines_read_field>ExecutionLinesRead</execution_lines_read_field>
|
||||
<execution_lines_written_field>ExecutionLinesWritten</execution_lines_written_field>
|
||||
<execution_lines_input_field>ExecutionLinesInput</execution_lines_input_field>
|
||||
<execution_lines_output_field>ExecutionLinesOutput</execution_lines_output_field>
|
||||
<execution_lines_rejected_field>ExecutionLinesRejected</execution_lines_rejected_field>
|
||||
<execution_lines_updated_field>ExecutionLinesUpdated</execution_lines_updated_field>
|
||||
<execution_lines_deleted_field>ExecutionLinesDeleted</execution_lines_deleted_field>
|
||||
<execution_files_retrieved_field>ExecutionFilesRetrieved</execution_files_retrieved_field>
|
||||
<execution_exit_status_field>ExecutionExitStatus</execution_exit_status_field>
|
||||
<execution_log_text_field>ExecutionLogText</execution_log_text_field>
|
||||
<execution_log_channelid_field>ExecutionLogChannelId</execution_log_channelid_field>
|
||||
<result_rows_target_transform/>
|
||||
<result_files_target_transform/>
|
||||
<result_files_file_name_field>FileName</result_files_file_name_field>
|
||||
<executors_output_transform/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>464</xloc>
|
||||
<yloc>528</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,185 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>recruitment_rows_five_flow_if_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/05/23 14:28:22.572</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/05/23 14:28:22.572</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Copy rows to result</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Copy rows to result</name>
|
||||
<type>RowsToResult</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>880</xloc>
|
||||
<yloc>288</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>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,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num,
|
||||
((rn - 1) % CEIL(total_rows / 5.0)) + 1 AS position
|
||||
FROM ordered
|
||||
),
|
||||
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 position
|
||||
),
|
||||
remains as (
|
||||
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
|
||||
cr_flow1,
|
||||
idm_flow1
|
||||
from remains
|
||||
where cr_flow1 is not null and idm_flow1 is not null
|
||||
),
|
||||
idm2 as (
|
||||
select
|
||||
cr_flow2,
|
||||
idm_flow2
|
||||
from remains
|
||||
where cr_flow2 is not null and idm_flow2 is not null
|
||||
),
|
||||
idm3 as (
|
||||
select
|
||||
cr_flow3,
|
||||
idm_flow3
|
||||
from remains
|
||||
where cr_flow3 is not null and idm_flow3 is not null
|
||||
),
|
||||
idm4 as (
|
||||
select
|
||||
cr_flow4,
|
||||
idm_flow4
|
||||
from remains
|
||||
where cr_flow4 is not null and idm_flow4 is not null
|
||||
),
|
||||
idm5 as (
|
||||
select
|
||||
cr_flow5,
|
||||
idm_flow5
|
||||
from remains
|
||||
where cr_flow5 is not null and idm_flow5 is not null
|
||||
)
|
||||
select
|
||||
i1.*,
|
||||
i2.*,
|
||||
i3.*,
|
||||
i4.*,
|
||||
i5.*
|
||||
FROM
|
||||
(SELECT *, ROW_NUMBER() OVER () as rn FROM idm1) i1
|
||||
FULL OUTER JOIN
|
||||
(SELECT *, ROW_NUMBER() OVER () as rn FROM idm2) i2 ON i1.rn = i2.rn
|
||||
FULL OUTER JOIN
|
||||
(SELECT *, ROW_NUMBER() OVER () as rn FROM idm3) i3 ON i1.rn = i3.rn
|
||||
FULL OUTER JOIN
|
||||
(SELECT *, ROW_NUMBER() OVER () as rn FROM idm4) i4 ON i1.rn = i4.rn
|
||||
FULL OUTER JOIN
|
||||
(SELECT *, ROW_NUMBER() OVER () as rn FROM idm5) i5 ON i1.rn = i5.rn
|
||||
ORDER BY COALESCE(i1.rn, i2.rn, i3.rn, i4.rn, i5.rn)
|
||||
limit 2</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>512</xloc>
|
||||
<yloc>288</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -0,0 +1,356 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>recruitments_five_flow</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/04/18 09:48:01.970</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/04/18 09:48:01.970</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Get all recruitments ordered by created_date</from>
|
||||
<to>child_flow.hpl</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Get all recruitments ordered by created_date</from>
|
||||
<to>child_flow.hpl 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Get all recruitments ordered by created_date</from>
|
||||
<to>child_flow.hpl 3</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Get all recruitments ordered by created_date</from>
|
||||
<to>child_flow.hpl 4</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Get all recruitments ordered by created_date</from>
|
||||
<to>child_flow.hpl 5</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Get all recruitments ordered by created_date</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit/>
|
||||
<sql>SELECT
|
||||
idm_id AS recruitment
|
||||
FROM ervu_dashboard.recruitment;</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>432</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>child_flow.hpl</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
<group_field/>
|
||||
<group_time/>
|
||||
<parameters>
|
||||
<variable_mapping>
|
||||
<variable>IDM_ID</variable>
|
||||
<field>recruitment</field>
|
||||
<input/>
|
||||
</variable_mapping>
|
||||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
<execution_result_target_transform>Change job status on success </execution_result_target_transform>
|
||||
<execution_time_field>ExecutionTime</execution_time_field>
|
||||
<execution_result_field>ExecutionResult</execution_result_field>
|
||||
<execution_errors_field>ExecutionNrErrors</execution_errors_field>
|
||||
<execution_lines_read_field>ExecutionLinesRead</execution_lines_read_field>
|
||||
<execution_lines_written_field>ExecutionLinesWritten</execution_lines_written_field>
|
||||
<execution_lines_input_field>ExecutionLinesInput</execution_lines_input_field>
|
||||
<execution_lines_output_field>ExecutionLinesOutput</execution_lines_output_field>
|
||||
<execution_lines_rejected_field>ExecutionLinesRejected</execution_lines_rejected_field>
|
||||
<execution_lines_updated_field>ExecutionLinesUpdated</execution_lines_updated_field>
|
||||
<execution_lines_deleted_field>ExecutionLinesDeleted</execution_lines_deleted_field>
|
||||
<execution_files_retrieved_field>ExecutionFilesRetrieved</execution_files_retrieved_field>
|
||||
<execution_exit_status_field>ExecutionExitStatus</execution_exit_status_field>
|
||||
<execution_log_text_field>ExecutionLogText</execution_log_text_field>
|
||||
<execution_log_channelid_field>ExecutionLogChannelId</execution_log_channelid_field>
|
||||
<result_rows_target_transform>Change job status on success </result_rows_target_transform>
|
||||
<result_files_target_transform/>
|
||||
<result_files_file_name_field>FileName</result_files_file_name_field>
|
||||
<executors_output_transform/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>704</xloc>
|
||||
<yloc>144</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>child_flow.hpl 2</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
<group_field/>
|
||||
<group_time/>
|
||||
<parameters>
|
||||
<variable_mapping>
|
||||
<variable>IDM_ID</variable>
|
||||
<field>recruitment</field>
|
||||
<input/>
|
||||
</variable_mapping>
|
||||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
<execution_result_target_transform>Change job status on success 2</execution_result_target_transform>
|
||||
<execution_time_field>ExecutionTime</execution_time_field>
|
||||
<execution_result_field>ExecutionResult</execution_result_field>
|
||||
<execution_errors_field>ExecutionNrErrors</execution_errors_field>
|
||||
<execution_lines_read_field>ExecutionLinesRead</execution_lines_read_field>
|
||||
<execution_lines_written_field>ExecutionLinesWritten</execution_lines_written_field>
|
||||
<execution_lines_input_field>ExecutionLinesInput</execution_lines_input_field>
|
||||
<execution_lines_output_field>ExecutionLinesOutput</execution_lines_output_field>
|
||||
<execution_lines_rejected_field>ExecutionLinesRejected</execution_lines_rejected_field>
|
||||
<execution_lines_updated_field>ExecutionLinesUpdated</execution_lines_updated_field>
|
||||
<execution_lines_deleted_field>ExecutionLinesDeleted</execution_lines_deleted_field>
|
||||
<execution_files_retrieved_field>ExecutionFilesRetrieved</execution_files_retrieved_field>
|
||||
<execution_exit_status_field>ExecutionExitStatus</execution_exit_status_field>
|
||||
<execution_log_text_field>ExecutionLogText</execution_log_text_field>
|
||||
<execution_log_channelid_field>ExecutionLogChannelId</execution_log_channelid_field>
|
||||
<result_rows_target_transform>Change job status on success 2</result_rows_target_transform>
|
||||
<result_files_target_transform/>
|
||||
<result_files_file_name_field>FileName</result_files_file_name_field>
|
||||
<executors_output_transform/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>704</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>child_flow.hpl 3</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
<group_field/>
|
||||
<group_time/>
|
||||
<parameters>
|
||||
<variable_mapping>
|
||||
<variable>IDM_ID</variable>
|
||||
<field>recruitment</field>
|
||||
<input/>
|
||||
</variable_mapping>
|
||||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
<execution_result_target_transform>Change job status on success 4</execution_result_target_transform>
|
||||
<execution_time_field>ExecutionTime</execution_time_field>
|
||||
<execution_result_field>ExecutionResult</execution_result_field>
|
||||
<execution_errors_field>ExecutionNrErrors</execution_errors_field>
|
||||
<execution_lines_read_field>ExecutionLinesRead</execution_lines_read_field>
|
||||
<execution_lines_written_field>ExecutionLinesWritten</execution_lines_written_field>
|
||||
<execution_lines_input_field>ExecutionLinesInput</execution_lines_input_field>
|
||||
<execution_lines_output_field>ExecutionLinesOutput</execution_lines_output_field>
|
||||
<execution_lines_rejected_field>ExecutionLinesRejected</execution_lines_rejected_field>
|
||||
<execution_lines_updated_field>ExecutionLinesUpdated</execution_lines_updated_field>
|
||||
<execution_lines_deleted_field>ExecutionLinesDeleted</execution_lines_deleted_field>
|
||||
<execution_files_retrieved_field>ExecutionFilesRetrieved</execution_files_retrieved_field>
|
||||
<execution_exit_status_field>ExecutionExitStatus</execution_exit_status_field>
|
||||
<execution_log_text_field>ExecutionLogText</execution_log_text_field>
|
||||
<execution_log_channelid_field>ExecutionLogChannelId</execution_log_channelid_field>
|
||||
<result_rows_target_transform>Change job status on success 3</result_rows_target_transform>
|
||||
<result_files_target_transform/>
|
||||
<result_files_file_name_field>FileName</result_files_file_name_field>
|
||||
<executors_output_transform/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>704</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>child_flow.hpl 4</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
<group_field/>
|
||||
<group_time/>
|
||||
<parameters>
|
||||
<variable_mapping>
|
||||
<variable>IDM_ID</variable>
|
||||
<field>recruitment</field>
|
||||
<input/>
|
||||
</variable_mapping>
|
||||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
<execution_result_target_transform>Change job status on success 4</execution_result_target_transform>
|
||||
<execution_time_field>ExecutionTime</execution_time_field>
|
||||
<execution_result_field>ExecutionResult</execution_result_field>
|
||||
<execution_errors_field>ExecutionNrErrors</execution_errors_field>
|
||||
<execution_lines_read_field>ExecutionLinesRead</execution_lines_read_field>
|
||||
<execution_lines_written_field>ExecutionLinesWritten</execution_lines_written_field>
|
||||
<execution_lines_input_field>ExecutionLinesInput</execution_lines_input_field>
|
||||
<execution_lines_output_field>ExecutionLinesOutput</execution_lines_output_field>
|
||||
<execution_lines_rejected_field>ExecutionLinesRejected</execution_lines_rejected_field>
|
||||
<execution_lines_updated_field>ExecutionLinesUpdated</execution_lines_updated_field>
|
||||
<execution_lines_deleted_field>ExecutionLinesDeleted</execution_lines_deleted_field>
|
||||
<execution_files_retrieved_field>ExecutionFilesRetrieved</execution_files_retrieved_field>
|
||||
<execution_exit_status_field>ExecutionExitStatus</execution_exit_status_field>
|
||||
<execution_log_text_field>ExecutionLogText</execution_log_text_field>
|
||||
<execution_log_channelid_field>ExecutionLogChannelId</execution_log_channelid_field>
|
||||
<result_rows_target_transform>Change job status on success 4</result_rows_target_transform>
|
||||
<result_files_target_transform/>
|
||||
<result_files_file_name_field>FileName</result_files_file_name_field>
|
||||
<executors_output_transform/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>704</xloc>
|
||||
<yloc>384</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>child_flow.hpl 5</name>
|
||||
<type>PipelineExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/child/parallel/child_flow.hpl</filename>
|
||||
<filenameInField>N</filenameInField>
|
||||
<filenameField/>
|
||||
<group_size>1</group_size>
|
||||
<group_field/>
|
||||
<group_time/>
|
||||
<parameters>
|
||||
<variable_mapping>
|
||||
<variable>IDM_ID</variable>
|
||||
<field>recruitment</field>
|
||||
<input/>
|
||||
</variable_mapping>
|
||||
<variable_mapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>child_job</input>
|
||||
</variable_mapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
<execution_result_target_transform>Change job status on success 5</execution_result_target_transform>
|
||||
<execution_time_field>ExecutionTime</execution_time_field>
|
||||
<execution_result_field>ExecutionResult</execution_result_field>
|
||||
<execution_errors_field>ExecutionNrErrors</execution_errors_field>
|
||||
<execution_lines_read_field>ExecutionLinesRead</execution_lines_read_field>
|
||||
<execution_lines_written_field>ExecutionLinesWritten</execution_lines_written_field>
|
||||
<execution_lines_input_field>ExecutionLinesInput</execution_lines_input_field>
|
||||
<execution_lines_output_field>ExecutionLinesOutput</execution_lines_output_field>
|
||||
<execution_lines_rejected_field>ExecutionLinesRejected</execution_lines_rejected_field>
|
||||
<execution_lines_updated_field>ExecutionLinesUpdated</execution_lines_updated_field>
|
||||
<execution_lines_deleted_field>ExecutionLinesDeleted</execution_lines_deleted_field>
|
||||
<execution_files_retrieved_field>ExecutionFilesRetrieved</execution_files_retrieved_field>
|
||||
<execution_exit_status_field>ExecutionExitStatus</execution_exit_status_field>
|
||||
<execution_log_text_field>ExecutionLogText</execution_log_text_field>
|
||||
<execution_log_channelid_field>ExecutionLogChannelId</execution_log_channelid_field>
|
||||
<result_rows_target_transform>Change job status on success 5</result_rows_target_transform>
|
||||
<result_files_target_transform/>
|
||||
<result_files_file_name_field>FileName</result_files_file_name_field>
|
||||
<executors_output_transform/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>704</xloc>
|
||||
<yloc>464</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -87,11 +87,8 @@
|
|||
</argument>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<delete_field/>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<insert_field/>
|
||||
<quoteString>N</quoteString>
|
||||
<read_field/>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>Y</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
|
|
@ -102,7 +99,6 @@ WHERE job_name = '${JOB_NAME}'
|
|||
and recruitment_id = '${IDM_ID}';
|
||||
|
||||
</sql>
|
||||
<update_field/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>944</xloc>
|
||||
|
|
@ -182,6 +178,7 @@ VALUES (DEFAULT, '${JOB_NAME}', 'PROCESSING', DEFAULT, null, '${IDM_ID}');
|
|||
</partitioning>
|
||||
<connection>ervu_person_registry</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit/>
|
||||
<sql>/*
|
||||
with
|
||||
adresses as ( -- по одному ли адресу тут должно быть??
|
||||
|
|
@ -224,7 +221,7 @@ SELECT
|
|||
r.vu_current_info,
|
||||
r.military_registration_date AS date_registration,
|
||||
r.vu_unset_date AS date_deregistration,
|
||||
--ri.info->'svedFL'->'svedSemPolozh'->>'semPolozhNaim' AS marital_status,
|
||||
NULLIF(ri.info->'svedFL'->'svedSemPolozh'->>'semPolozh','')::int AS marital_status,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'nomDok' AS passport_number,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'serDok' AS passport_series,
|
||||
--ri.info->'svedFL'->'svedVoin'->'voin'->>'dataReg' AS issue_date,
|
||||
|
|
@ -383,16 +380,23 @@ ${LIMIT_FW}</sql>
|
|||
<column_name>id_ern</column_name>
|
||||
<stream_name>id_ern</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>marital_status</column_name>
|
||||
<stream_name>marital_status</stream_name>
|
||||
</field>
|
||||
</fields>
|
||||
<ignore_errors>N</ignore_errors>
|
||||
<only_when_have_rows>N</only_when_have_rows>
|
||||
<partitioning_daily>N</partitioning_daily>
|
||||
<partitioning_enabled>N</partitioning_enabled>
|
||||
<partitioning_field/>
|
||||
<partitioning_monthly>Y</partitioning_monthly>
|
||||
<return_field/>
|
||||
<return_keys>N</return_keys>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<specify_fields>Y</specify_fields>
|
||||
<table>citizen</table>
|
||||
<tablename_field/>
|
||||
<tablename_in_field>N</tablename_in_field>
|
||||
<tablename_in_table>Y</tablename_in_table>
|
||||
<truncate>N</truncate>
|
||||
|
|
|
|||
|
|
@ -27,11 +27,31 @@
|
|||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Identify last row in a stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Identify last row in a stream</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Insert / update</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Filter rows</from>
|
||||
<to>Change job status on success</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Insert / update</from>
|
||||
<to>Detect empty stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Detect empty stream</from>
|
||||
<to>Change job status on success</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
|
|
@ -40,7 +60,32 @@
|
|||
<to>Change job status on error</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Change job status on error</from>
|
||||
<to>Abort</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Abort</name>
|
||||
<type>Abort</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<abort_option>ABORT_WITH_ERROR</abort_option>
|
||||
<always_log_rows>Y</always_log_rows>
|
||||
<row_threshold>0</row_threshold>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>384</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on error</name>
|
||||
<type>ExecSql</type>
|
||||
|
|
@ -56,9 +101,6 @@
|
|||
<argument>
|
||||
<name>error_description</name>
|
||||
</argument>
|
||||
<argument>
|
||||
<name>error_code</name>
|
||||
</argument>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
|
|
@ -68,16 +110,15 @@
|
|||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET status = 'DELTA_ERROR',
|
||||
error_description = ?,
|
||||
error_code = ?
|
||||
error_description = ?
|
||||
WHERE job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1040</xloc>
|
||||
<yloc>416</yloc>
|
||||
<xloc>832</xloc>
|
||||
<yloc>384</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
|
|
@ -107,8 +148,8 @@ and recruitment_id = '${IDM_ID}';
|
|||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1040</xloc>
|
||||
<yloc>224</yloc>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>80</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
|
|
@ -134,13 +175,83 @@ and recruitment_id = '${IDM_ID}';
|
|||
SET
|
||||
status = 'DELTA_PROCESSING',
|
||||
execution_datetime = DEFAULT,
|
||||
error_description = NULL,
|
||||
error_code = NULL
|
||||
error_description = NULL
|
||||
where job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>336</xloc>
|
||||
<xloc>272</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Detect empty stream</name>
|
||||
<type>DetectEmptyStream</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Filter rows</name>
|
||||
<type>FilterRows</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compare>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>last_row</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>Y</text>
|
||||
<type>Boolean</type>
|
||||
</value>
|
||||
</condition>
|
||||
</compare>
|
||||
<send_true_to>Change job status on success</send_true_to>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>832</xloc>
|
||||
<yloc>80</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Identify last row in a stream</name>
|
||||
<type>DetectLastRow</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<resultfieldname>last_row</resultfieldname>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
|
|
@ -148,7 +259,7 @@ and recruitment_id = '${IDM_ID}';</sql>
|
|||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
|
|
@ -162,7 +273,6 @@ and recruitment_id = '${IDM_ID}';</sql>
|
|||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
<name2/>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen</table>
|
||||
|
|
@ -271,11 +381,16 @@ and recruitment_id = '${IDM_ID}';</sql>
|
|||
<rename>id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>marital_status</name>
|
||||
<rename>marital_status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<xloc>832</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
|
|
@ -283,7 +398,7 @@ and recruitment_id = '${IDM_ID}';</sql>
|
|||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
|
|
@ -292,6 +407,7 @@ and recruitment_id = '${IDM_ID}';</sql>
|
|||
</partitioning>
|
||||
<connection>ervu_person_registry</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit/>
|
||||
<sql>/*
|
||||
with
|
||||
adresses as ( -- по одному ли адресу тут должно быть??
|
||||
|
|
@ -334,7 +450,7 @@ SELECT
|
|||
r.vu_current_info,
|
||||
r.military_registration_date AS date_registration,
|
||||
r.vu_unset_date AS date_deregistration,
|
||||
--ri.info->'svedFL'->'svedSemPolozh'->>'semPolozhNaim' AS marital_status,
|
||||
NULLIF(ri.info->'svedFL'->'svedSemPolozh'->>'semPolozh','')::int AS marital_status,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'nomDok' AS passport_number,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'serDok' AS passport_series,
|
||||
--ri.info->'svedFL'->'svedVoin'->'voin'->>'dataReg' AS issue_date,
|
||||
|
|
@ -372,7 +488,8 @@ SELECT
|
|||
FROM public.recruits AS r
|
||||
JOIN public.recruits_info AS ri ON ri.recruit_id = r.id AND '${IDM_ID}' != '' -- Проверка на пустую строку
|
||||
AND COALESCE(current_recruitment_id, target_recruitment_id) = '${IDM_ID}'
|
||||
AND '${M_R_CR_DATE}' >= r.system_create_date::timestamp
|
||||
--AND '${M_R_CR_DATE}' >= r.system_create_date::timestamp
|
||||
AND r.system_update_date >= '${M_R_UP_DATE}'::timestamp
|
||||
LEFT JOIN (
|
||||
SELECT
|
||||
ROW_NUMBER() OVER (PARTITION BY recruit_id ORDER BY created_at DESC) as rn,
|
||||
|
|
@ -391,7 +508,7 @@ ${LIMIT_FW}</sql>
|
|||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>544</xloc>
|
||||
<xloc>464</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
|
|
|
|||
|
|
@ -27,20 +27,65 @@
|
|||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Table output</to>
|
||||
<to>Identify last row in a stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table output</from>
|
||||
<from>Identify last row in a stream</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Insert / update</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Insert / update</from>
|
||||
<to>Detect empty stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Detect empty stream</from>
|
||||
<to>Change job status on success</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table output</from>
|
||||
<from>Filter rows</from>
|
||||
<to>Change job status on success</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Insert / update</from>
|
||||
<to>Change job status on error</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Change job status on error</from>
|
||||
<to>Abort</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Abort</name>
|
||||
<type>Abort</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<abort_option>ABORT_WITH_ERROR</abort_option>
|
||||
<always_log_rows>Y</always_log_rows>
|
||||
<row_threshold>0</row_threshold>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on error</name>
|
||||
<type>ExecSql</type>
|
||||
|
|
@ -56,13 +101,13 @@
|
|||
<argument>
|
||||
<name>error_description</name>
|
||||
</argument>
|
||||
<argument>
|
||||
<name>error_code</name>
|
||||
</argument>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<delete_field/>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<insert_field/>
|
||||
<quoteString>N</quoteString>
|
||||
<read_field/>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>Y</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
|
|
@ -73,10 +118,11 @@ WHERE job_name = '${JOB_NAME}'
|
|||
and recruitment_id = '${IDM_ID}';
|
||||
|
||||
</sql>
|
||||
<update_field/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>976</xloc>
|
||||
<yloc>400</yloc>
|
||||
<xloc>896</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
|
|
@ -106,8 +152,8 @@ and recruitment_id = '${IDM_ID}';
|
|||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>976</xloc>
|
||||
<yloc>208</yloc>
|
||||
<xloc>1216</xloc>
|
||||
<yloc>96</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
|
|
@ -135,7 +181,6 @@ and recruitment_id = '${IDM_ID}';
|
|||
status,
|
||||
execution_datetime,
|
||||
error_description,
|
||||
error_code,
|
||||
recruitment_id
|
||||
)
|
||||
VALUES (
|
||||
|
|
@ -144,26 +189,234 @@ VALUES (
|
|||
'PROCESSING',
|
||||
DEFAULT,
|
||||
NULL,
|
||||
NULL,
|
||||
'${IDM_ID}'
|
||||
)
|
||||
ON CONFLICT (job_name, recruitment_id)
|
||||
DO UPDATE SET
|
||||
status = 'PROCESSING',
|
||||
execution_datetime = DEFAULT,
|
||||
error_description = NULL,
|
||||
error_code = NULL;</sql>
|
||||
error_description = NULL</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>272</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Detect empty stream</name>
|
||||
<type>DetectEmptyStream</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1216</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Filter rows</name>
|
||||
<type>FilterRows</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compare>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>last_row</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>Y</text>
|
||||
<type>Boolean</type>
|
||||
</value>
|
||||
</condition>
|
||||
</compare>
|
||||
<send_true_to>Change job status on success</send_true_to>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>896</xloc>
|
||||
<yloc>96</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Identify last row in a stream</name>
|
||||
<type>DetectLastRow</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<resultfieldname>last_row</resultfieldname>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>system_pgs_status</name>
|
||||
<rename>system_pgs_status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>full_name</name>
|
||||
<rename>full_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_name</name>
|
||||
<rename>last_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>first_name</name>
|
||||
<rename>first_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>middle_name</name>
|
||||
<rename>middle_name</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>gender</name>
|
||||
<rename>gender</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_date</name>
|
||||
<rename>birth_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>age</name>
|
||||
<rename>age</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>birth_place</name>
|
||||
<rename>birth_place</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>phone</name>
|
||||
<rename>phone</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>email</name>
|
||||
<rename>email</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>vu_current_info</name>
|
||||
<rename>vu_current_info</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>date_registration</name>
|
||||
<rename>date_registration</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>date_deregistration</name>
|
||||
<rename>date_deregistration</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>marital_status</name>
|
||||
<rename>marital_status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruit_create_date</name>
|
||||
<rename>recruit_create_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>update_date</name>
|
||||
<rename>update_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_id</name>
|
||||
<rename>recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>target_recruitment_id</name>
|
||||
<rename>target_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>deferment_liberation</name>
|
||||
<rename>deferment_liberation</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>id_ern</name>
|
||||
<rename>id_ern</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>896</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
|
|
@ -214,7 +467,7 @@ SELECT
|
|||
r.vu_current_info,
|
||||
r.military_registration_date AS date_registration,
|
||||
r.vu_unset_date AS date_deregistration,
|
||||
--ri.info->'svedFL'->'svedSemPolozh'->>'semPolozhNaim' AS marital_status,
|
||||
NULLIF(ri.info->'svedFL'->'svedSemPolozh'->>'semPolozh','')::int AS marital_status,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'nomDok' AS passport_number,
|
||||
--ri.info->'svedFL'->'pasportRF'->'aktPasportRF'->>'serDok' AS passport_series,
|
||||
--ri.info->'svedFL'->'svedVoin'->'voin'->>'dataReg' AS issue_date,
|
||||
|
|
@ -373,32 +626,33 @@ ${LIMIT_FW}</sql>
|
|||
<column_name>id_ern</column_name>
|
||||
<stream_name>id_ern</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>marital_status</column_name>
|
||||
<stream_name>marital_status</stream_name>
|
||||
</field>
|
||||
</fields>
|
||||
<ignore_errors>N</ignore_errors>
|
||||
<only_when_have_rows>N</only_when_have_rows>
|
||||
<partitioning_daily>N</partitioning_daily>
|
||||
<partitioning_enabled>N</partitioning_enabled>
|
||||
<partitioning_field/>
|
||||
<partitioning_monthly>Y</partitioning_monthly>
|
||||
<return_field/>
|
||||
<return_keys>N</return_keys>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<specify_fields>Y</specify_fields>
|
||||
<table>citizen</table>
|
||||
<tablename_field/>
|
||||
<tablename_in_field>N</tablename_in_field>
|
||||
<tablename_in_table>Y</tablename_in_table>
|
||||
<truncate>N</truncate>
|
||||
<use_batch>Y</use_batch>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>720</xloc>
|
||||
<yloc>208</yloc>
|
||||
<xloc>576</xloc>
|
||||
<yloc>528</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
<error>
|
||||
<source_transform>Table output</source_transform>
|
||||
<source_transform>Insert / update</source_transform>
|
||||
<target_transform>Change job status on error</target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
|
|
@ -409,6 +663,18 @@ ${LIMIT_FW}</sql>
|
|||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
<error>
|
||||
<source_transform>Table output</source_transform>
|
||||
<target_transform>Change job status on error</target_transform>
|
||||
<is_enabled>N</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename/>
|
||||
<fields_valuename/>
|
||||
<codes_valuename/>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@
|
|||
<sql>SELECT
|
||||
r.idm_id as recruitment_id
|
||||
FROM ervu_dashboard.recruitment r
|
||||
LEFT JOIN public.job_execution je
|
||||
LEFT JOIN etl.job_execution je
|
||||
ON r.idm_id = je.recruitment_id
|
||||
and job_name = 'citizen_job'
|
||||
where je.status is null or je.status in('ERROR', 'PROCESSING');</sql>
|
||||
|
|
|
|||
|
|
@ -112,59 +112,6 @@ ${COMMENT}*/</sql>
|
|||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>job_citizen_flow.hwf</name>
|
||||
<type>WorkflowExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/citizen/parallel/job_citizen_flow.hwf</filename>
|
||||
<group_size>1</group_size>
|
||||
<group_field/>
|
||||
<group_time/>
|
||||
<parameters>
|
||||
<variablemapping>
|
||||
<variable>IDM_ID</variable>
|
||||
<field>recruitment</field>
|
||||
<input/>
|
||||
</variablemapping>
|
||||
<variablemapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>citizen_job</input>
|
||||
</variablemapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
<execution_result_target_transform/>
|
||||
<execution_time_field>ExecutionTime</execution_time_field>
|
||||
<execution_result_field>ExecutionResult</execution_result_field>
|
||||
<execution_errors_field>ExecutionNrErrors</execution_errors_field>
|
||||
<execution_lines_read_field>ExecutionLinesRead</execution_lines_read_field>
|
||||
<execution_lines_written_field>ExecutionLinesWritten</execution_lines_written_field>
|
||||
<execution_lines_input_field>ExecutionLinesInput</execution_lines_input_field>
|
||||
<execution_lines_output_field>ExecutionLinesOutput</execution_lines_output_field>
|
||||
<execution_lines_rejected_field>ExecutionLinesRejected</execution_lines_rejected_field>
|
||||
<execution_lines_updated_field>ExecutionLinesUpdated</execution_lines_updated_field>
|
||||
<execution_lines_deleted_field>ExecutionLinesDeleted</execution_lines_deleted_field>
|
||||
<execution_files_retrieved_field>ExecutionFilesRetrieved</execution_files_retrieved_field>
|
||||
<execution_exit_status_field>ExecutionExitStatus</execution_exit_status_field>
|
||||
<execution_log_text_field>ExecutionLogText</execution_log_text_field>
|
||||
<execution_log_channelid_field>ExecutionLogChannelId</execution_log_channelid_field>
|
||||
<result_rows_target_transform/>
|
||||
<result_files_target_transform/>
|
||||
<result_files_file_name_field>FileName</result_files_file_name_field>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>736</xloc>
|
||||
<yloc>144</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>citizen_flow.hpl</name>
|
||||
<type>PipelineExecutor</type>
|
||||
|
|
@ -445,6 +392,59 @@ ${COMMENT}*/</sql>
|
|||
<yloc>928</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>job_citizen_flow.hwf</name>
|
||||
<type>WorkflowExecutor</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<run_configuration>local</run_configuration>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/citizen/parallel/job_citizen_flow.hwf</filename>
|
||||
<group_size>1</group_size>
|
||||
<group_field/>
|
||||
<group_time/>
|
||||
<parameters>
|
||||
<variablemapping>
|
||||
<variable>IDM_ID</variable>
|
||||
<field>recruitment</field>
|
||||
<input/>
|
||||
</variablemapping>
|
||||
<variablemapping>
|
||||
<variable>JOB_NAME</variable>
|
||||
<field/>
|
||||
<input>citizen_job</input>
|
||||
</variablemapping>
|
||||
<inherit_all_vars>Y</inherit_all_vars>
|
||||
</parameters>
|
||||
<execution_result_target_transform/>
|
||||
<execution_time_field>ExecutionTime</execution_time_field>
|
||||
<execution_result_field>ExecutionResult</execution_result_field>
|
||||
<execution_errors_field>ExecutionNrErrors</execution_errors_field>
|
||||
<execution_lines_read_field>ExecutionLinesRead</execution_lines_read_field>
|
||||
<execution_lines_written_field>ExecutionLinesWritten</execution_lines_written_field>
|
||||
<execution_lines_input_field>ExecutionLinesInput</execution_lines_input_field>
|
||||
<execution_lines_output_field>ExecutionLinesOutput</execution_lines_output_field>
|
||||
<execution_lines_rejected_field>ExecutionLinesRejected</execution_lines_rejected_field>
|
||||
<execution_lines_updated_field>ExecutionLinesUpdated</execution_lines_updated_field>
|
||||
<execution_lines_deleted_field>ExecutionLinesDeleted</execution_lines_deleted_field>
|
||||
<execution_files_retrieved_field>ExecutionFilesRetrieved</execution_files_retrieved_field>
|
||||
<execution_exit_status_field>ExecutionExitStatus</execution_exit_status_field>
|
||||
<execution_log_text_field>ExecutionLogText</execution_log_text_field>
|
||||
<execution_log_channelid_field>ExecutionLogChannelId</execution_log_channelid_field>
|
||||
<result_rows_target_transform/>
|
||||
<result_files_target_transform/>
|
||||
<result_files_file_name_field>FileName</result_files_file_name_field>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>736</xloc>
|
||||
<yloc>144</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>job_citizen_flow.hwf 2</name>
|
||||
<type>WorkflowExecutor</type>
|
||||
|
|
|
|||
|
|
@ -1,124 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>branching_citizen_appealing_violations_fz53</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/09 09:54:43.724</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/09 09:54:43.724</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Set variables 2</from>
|
||||
<to>Write to log 2</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Set variables 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Set variables 2</name>
|
||||
<type>SetVariable</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<fields>
|
||||
<field>
|
||||
<field_name>pipeline</field_name>
|
||||
<variable_name>PIPE</variable_name>
|
||||
<variable_type>PARENT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
<field>
|
||||
<field_name>status</field_name>
|
||||
<variable_name>STATUS</variable_name>
|
||||
<variable_type>PARENT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
</fields>
|
||||
<use_formatting>Y</use_formatting>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>256</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>select
|
||||
status as STATUS,
|
||||
job_name AS PIPELINE
|
||||
from public.etl_checkpoints
|
||||
where job_name = 'job_citizen_appealing_violations_fz53'</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>816</xloc>
|
||||
<yloc>256</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Write to log 2</name>
|
||||
<type>WriteToLog</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<displayHeader>Y</displayHeader>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
</field>
|
||||
</fields>
|
||||
<limitRows>N</limitRows>
|
||||
<limitRowsNumber>0</limitRowsNumber>
|
||||
<loglevel>Basic</loglevel>
|
||||
<logmessage>${PIPE}
|
||||
${STATUS}</logmessage>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1280</xloc>
|
||||
<yloc>256</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,142 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>branching_citizen_appealing_violations_fz53_delta</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/09 09:54:43.724</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/09 09:54:43.724</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Set variables 2</from>
|
||||
<to>Write to log 2</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Set variables 2</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Set variables 2</name>
|
||||
<type>SetVariable</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<fields>
|
||||
<field>
|
||||
<field_name>pipeline</field_name>
|
||||
<variable_name>PIPE</variable_name>
|
||||
<variable_type>PARENT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
<field>
|
||||
<field_name>status</field_name>
|
||||
<variable_name>STATUS</variable_name>
|
||||
<variable_type>PARENT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
</fields>
|
||||
<use_formatting>Y</use_formatting>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>256</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT
|
||||
COALESCE(job_name, 'job_citizen_appealing_violations_fz53_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_citizen_appealing_violations_fz53_delta'
|
||||
|
||||
UNION ALL
|
||||
|
||||
SELECT NULL, NULL
|
||||
WHERE NOT EXISTS (
|
||||
SELECT 1
|
||||
FROM public.etl_checkpoints
|
||||
WHERE job_name = 'job_citizen_appealing_violations_fz53_delta'
|
||||
)
|
||||
) t</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>816</xloc>
|
||||
<yloc>256</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Write to log 2</name>
|
||||
<type>WriteToLog</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<displayHeader>Y</displayHeader>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
</field>
|
||||
</fields>
|
||||
<limitRows>N</limitRows>
|
||||
<limitRowsNumber>0</limitRowsNumber>
|
||||
<loglevel>Basic</loglevel>
|
||||
<logmessage>${PIPE}
|
||||
${STATUS}</logmessage>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1280</xloc>
|
||||
<yloc>256</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_child_flow4_error</name>
|
||||
<name>check_if_need_to_repeat_job</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
|
|
@ -13,22 +13,22 @@
|
|||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<created_date>2025/08/08 12:27:51.630</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
<modified_date>2025/08/08 12:27:51.630</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<to>Set variables</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<name>Set variables</name>
|
||||
<type>SetVariable</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
|
|
@ -37,37 +37,18 @@
|
|||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<fields>
|
||||
<field>
|
||||
<field_name>need_to_repeat_job</field_name>
|
||||
<variable_name>NEED_TO_REPEAT_JOB</variable_name>
|
||||
<variable_type>ROOT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
</fields>
|
||||
<use_formatting>Y</use_formatting>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
<xloc>624</xloc>
|
||||
<yloc>288</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
|
|
@ -84,15 +65,19 @@
|
|||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_child_flow4' as job_name,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created</sql>
|
||||
<sql>SELECT EXISTS (SELECT 1
|
||||
FROM ervu_dashboard.recruitment r
|
||||
LEFT JOIN etl.job_execution je
|
||||
ON r.idm_id = je.recruitment_id
|
||||
and job_name = 'citizen_appealing_violations_fz53_job'
|
||||
where je.status is null or je.status in ('ERROR', 'PROCESSING')
|
||||
limit 1
|
||||
) as need_to_repeat_job;</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
<xloc>336</xloc>
|
||||
<yloc>288</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
|
|
@ -1,250 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_citizen_appealing_violations_fz53_flow1_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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_appealing_violations_fz53 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
|
||||
),
|
||||
for_checkpoints as (
|
||||
SELECT
|
||||
'citizen_appealing_violations_fz53_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,250 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_citizen_appealing_violations_fz53_flow1_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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_appealing_violations_fz53 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
|
||||
),
|
||||
for_checkpoints as (
|
||||
SELECT
|
||||
'citizen_appealing_violations_fz53_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,254 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_citizen_appealing_violations_fz53_flow2_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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_appealing_violations_fz53 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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'citizen_appealing_violations_fz53_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,254 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_citizen_appealing_violations_fz53_flow2_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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_appealing_violations_fz53 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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'citizen_appealing_violations_fz53_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,255 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_citizen_appealing_violations_fz53_flow3_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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_appealing_violations_fz53 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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'citizen_appealing_violations_fz53_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,255 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_citizen_appealing_violations_fz53_flow3_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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_appealing_violations_fz53 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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'citizen_appealing_violations_fz53_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,256 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_citizen_appealing_violations_fz53_flow4_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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_appealing_violations_fz53 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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'citizen_appealing_violations_fz53_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,256 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_citizen_appealing_violations_fz53_flow4_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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_appealing_violations_fz53 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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'citizen_appealing_violations_fz53_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
/*
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
*/
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,256 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_citizen_appealing_violations_fz53_flow5_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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_appealing_violations_fz53 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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'citizen_appealing_violations_fz53_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,256 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_citizen_appealing_violations_fz53_flow5_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 09:14:18.787</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 09:14:18.787</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>last_recruitment_id</name>
|
||||
<rename>last_recruitment_id</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>recruitment_created_date</name>
|
||||
<rename>recruitment_created_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1056</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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_appealing_violations_fz53 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
|
||||
),
|
||||
for_checkpoints as (
|
||||
/*
|
||||
SELECT
|
||||
'job_citizen_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_citizen_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
*/
|
||||
SELECT
|
||||
'citizen_appealing_violations_fz53_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,101 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_citizen_appealing_violations_fz53_flow1_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_snils_inn_flow1' as job_name,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,101 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_citizen_appealing_violations_fz53_flow1_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_snils_inn_flow1' as job_name,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,102 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_citizen_appealing_violations_fz53_flow2_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_snils_inn_flow2' as job_name,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,101 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_citizen_appealing_violations_fz53_flow2_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_snils_inn_flow2' as job_name,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,101 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_citizen_appealing_violations_fz53_flow3_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_snils_inn_flow3' as job_name,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,101 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_citizen_appealing_violations_fz53_flow3_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_snils_inn_flow3' as job_name,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,101 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_citizen_appealing_violations_fz53_flow4_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_snils_inn_flow4' as job_name,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,101 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_citizen_appealing_violations_fz53_flow4_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_snils_inn_flow4' as job_name,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,101 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_citizen_appealing_violations_fz53_flow5_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_snils_inn_flow5' as job_name,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,101 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_delta_citizen_appealing_violations_fz53_flow5_success</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 12:20:06.191</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 12:20:06.191</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1152</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql> SELECT
|
||||
'delta_snils_inn_flow5' as job_name,
|
||||
'SUCCESS' as status,
|
||||
current_timestamp as record_created</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,142 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_to_processing</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/11 16:14:31.162</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/11 16:14:31.162</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>784</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT
|
||||
'PROCESSING' AS status,
|
||||
'job_citizen_appealing_violations_fz53' AS job_name,
|
||||
current_timestamp AS record_created
|
||||
--FROM public.etl_checkpoints
|
||||
|
||||
UNION ALL
|
||||
|
||||
SELECT
|
||||
'PROCESSING' AS status,
|
||||
'citizen_appealing_violations_fz53_flow1' AS job_name,
|
||||
current_timestamp AS record_created
|
||||
--FROM public.etl_checkpoints
|
||||
|
||||
UNION ALL
|
||||
|
||||
SELECT
|
||||
'PROCESSING' AS status,
|
||||
'citizen_appealing_violations_fz53_flow2' AS job_name,
|
||||
current_timestamp AS record_created
|
||||
--FROM public.etl_checkpoints
|
||||
|
||||
UNION ALL
|
||||
|
||||
SELECT
|
||||
'PROCESSING' AS status,
|
||||
'citizen_appealing_violations_fz53_flow3' AS job_name,
|
||||
current_timestamp AS record_created
|
||||
--FROM public.etl_checkpoints
|
||||
|
||||
UNION ALL
|
||||
|
||||
SELECT
|
||||
'PROCESSING' AS status,
|
||||
'citizen_appealing_violations_fz53_flow4' AS job_name,
|
||||
current_timestamp AS record_created
|
||||
--FROM public.etl_checkpoints
|
||||
|
||||
UNION ALL
|
||||
|
||||
SELECT
|
||||
'PROCESSING' AS status,
|
||||
'citizen_appealing_violations_fz53_flow5' AS job_name,
|
||||
current_timestamp AS record_created
|
||||
--FROM public.etl_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>368</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,102 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>change_status_to_processing_delta</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/16 13:42:26.494</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/16 13:42:26.494</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1248</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT
|
||||
'PROCESSING' AS status,
|
||||
'delta_snils_inn' AS job_name,
|
||||
current_timestamp AS record_created
|
||||
--FROM public.etl_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>832</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>check_if_job_child_exists</name>
|
||||
<name>check_if_citizen_appealing_violations_fz53_job_exists</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
|
|
@ -13,23 +13,23 @@
|
|||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/11 15:20:18.267</created_date>
|
||||
<created_date>2025/08/05 13:28:46.661</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/11 15:20:18.267</modified_date>
|
||||
<modified_date>2025/08/05 13:28:46.661</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Set variables</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Set variables</from>
|
||||
<to>Write to log</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Set variables</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Set variables</name>
|
||||
|
|
@ -44,21 +44,16 @@
|
|||
</partitioning>
|
||||
<fields>
|
||||
<field>
|
||||
<field_name>job_name</field_name>
|
||||
<variable_name>PIPE</variable_name>
|
||||
<variable_type>PARENT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
<field>
|
||||
<field_name>status</field_name>
|
||||
<variable_name>STATUS</variable_name>
|
||||
<field_name>job_executed_flag</field_name>
|
||||
<variable_name>JOB_EXECUTED_FLAG</variable_name>
|
||||
<variable_type>PARENT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
</fields>
|
||||
<use_formatting>Y</use_formatting>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>352</yloc>
|
||||
<xloc>672</xloc>
|
||||
<yloc>336</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
|
|
@ -75,29 +70,17 @@
|
|||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT
|
||||
COALESCE(job_name, 'job_child') AS job_name,
|
||||
COALESCE(status, 'NEW') AS status,
|
||||
current_timestamp::timestamp as record_created
|
||||
FROM (
|
||||
SELECT job_name, status
|
||||
FROM public.etl_checkpoints
|
||||
WHERE job_name = 'job_child'
|
||||
|
||||
UNION ALL
|
||||
|
||||
SELECT NULL, NULL
|
||||
WHERE NOT EXISTS (
|
||||
<sql>SELECT EXISTS (
|
||||
SELECT 1
|
||||
FROM public.etl_checkpoints
|
||||
WHERE job_name = 'job_child'
|
||||
)
|
||||
) t</sql>
|
||||
FROM etl.job_execution
|
||||
WHERE job_name = 'citizen_appealing_violations_fz53_job'
|
||||
limit 1
|
||||
) AS job_executed_flag;</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>400</xloc>
|
||||
<yloc>352</yloc>
|
||||
<xloc>384</xloc>
|
||||
<yloc>336</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
|
|
@ -120,8 +103,8 @@ FROM (
|
|||
<logmessage>${STATUS}</logmessage>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>960</xloc>
|
||||
<yloc>240</yloc>
|
||||
<xloc>944</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
|
|
@ -1,130 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>check_if_job_citizen_appealing_violations_fz53_exists</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/11 15:20:18.267</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/11 15:20:18.267</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Set variables</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Set variables</from>
|
||||
<to>Write to log</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Set variables</name>
|
||||
<type>SetVariable</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<fields>
|
||||
<field>
|
||||
<field_name>job_name</field_name>
|
||||
<variable_name>PIPE</variable_name>
|
||||
<variable_type>PARENT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
<field>
|
||||
<field_name>status</field_name>
|
||||
<variable_name>STATUS</variable_name>
|
||||
<variable_type>PARENT_WORKFLOW</variable_type>
|
||||
</field>
|
||||
</fields>
|
||||
<use_formatting>Y</use_formatting>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT
|
||||
COALESCE(job_name, 'job_citizen_appealing_violations_fz53') AS job_name,
|
||||
COALESCE(status, 'NEW') AS status,
|
||||
current_timestamp::timestamp as record_created
|
||||
FROM (
|
||||
SELECT job_name, status
|
||||
FROM public.etl_checkpoints
|
||||
WHERE job_name = 'job_citizen_appealing_violations_fz53'
|
||||
|
||||
UNION ALL
|
||||
|
||||
SELECT NULL, NULL
|
||||
WHERE NOT EXISTS (
|
||||
SELECT 1
|
||||
FROM public.etl_checkpoints
|
||||
WHERE job_name = 'job_citizen_appealing_violations_fz53'
|
||||
)
|
||||
) t</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>400</xloc>
|
||||
<yloc>352</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Write to log</name>
|
||||
<type>WriteToLog</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<displayHeader>Y</displayHeader>
|
||||
<fields>
|
||||
</fields>
|
||||
<limitRows>N</limitRows>
|
||||
<limitRowsNumber>0</limitRowsNumber>
|
||||
<loglevel>Basic</loglevel>
|
||||
<logmessage>${STATUS}</logmessage>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>960</xloc>
|
||||
<yloc>240</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,273 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>checkpoint_citizen_appealing_violations_fz53_error</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/09 10:01:04.895</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/09 10:01:04.895</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Select values</from>
|
||||
<to>Table output</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Select values</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Table output</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Select values</name>
|
||||
<type>SelectValues</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<fields>
|
||||
<select_unspecified>N</select_unspecified>
|
||||
<meta>
|
||||
<name>idm_id</name>
|
||||
<rename>idm_id</rename>
|
||||
<type>String</type>
|
||||
<length>-2</length>
|
||||
<precision>-2</precision>
|
||||
<conversion_mask/>
|
||||
<date_format_lenient>false</date_format_lenient>
|
||||
<date_format_locale/>
|
||||
<date_format_timezone/>
|
||||
<lenient_string_to_number>false</lenient_string_to_number>
|
||||
<encoding/>
|
||||
<decimal_symbol/>
|
||||
<grouping_symbol/>
|
||||
<currency_symbol/>
|
||||
<storage_type/>
|
||||
</meta>
|
||||
</fields>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1008</xloc>
|
||||
<yloc>608</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH ordered AS (
|
||||
SELECT
|
||||
idm_id,
|
||||
created_at,
|
||||
ROW_NUMBER() OVER (ORDER BY created_at) AS rn,
|
||||
COUNT(*) OVER () AS total_rows
|
||||
FROM ervu_dashboard.recruitment
|
||||
),
|
||||
splitted AS (
|
||||
SELECT *,
|
||||
CEIL(total_rows / 5.0) AS part_size,
|
||||
FLOOR((rn - 1) / CEIL(total_rows / 5.0)) + 1 AS flow_num
|
||||
FROM ordered
|
||||
),
|
||||
flow_ranges AS (
|
||||
SELECT
|
||||
flow_num,
|
||||
MIN(created_at) AS min_date,
|
||||
MAX(created_at) AS max_date
|
||||
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
|
||||
),
|
||||
for_checkpoints as (
|
||||
SELECT
|
||||
'job_child_flow1' as job_name,
|
||||
idm_flow1 as last_recruitment_id,
|
||||
cr_flow1 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_child_flow2' as job_name,
|
||||
idm_flow2 as last_recruitment_id,
|
||||
cr_flow2 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_child_flow3' as job_name,
|
||||
idm_flow3 as last_recruitment_id,
|
||||
cr_flow3 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_child_flow4' as job_name,
|
||||
idm_flow4 as last_recruitment_id,
|
||||
cr_flow4 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
|
||||
union all
|
||||
|
||||
SELECT
|
||||
'job_child_flow5' as job_name,
|
||||
idm_flow5 as last_recruitment_id,
|
||||
cr_flow5 as recruitment_created_date,
|
||||
'ERROR' as status,
|
||||
current_timestamp as record_created
|
||||
from result_max
|
||||
)
|
||||
select * from for_checkpoints</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>736</xloc>
|
||||
<yloc>448</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table output</name>
|
||||
<type>TableOutput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>1000</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<fields>
|
||||
</fields>
|
||||
<ignore_errors>N</ignore_errors>
|
||||
<only_when_have_rows>N</only_when_have_rows>
|
||||
<partitioning_daily>N</partitioning_daily>
|
||||
<partitioning_enabled>N</partitioning_enabled>
|
||||
<partitioning_monthly>Y</partitioning_monthly>
|
||||
<return_keys>N</return_keys>
|
||||
<schema>public</schema>
|
||||
<specify_fields>N</specify_fields>
|
||||
<table>etl_checkpoints</table>
|
||||
<tablename_in_field>N</tablename_in_field>
|
||||
<tablename_in_table>Y</tablename_in_table>
|
||||
<truncate>N</truncate>
|
||||
<use_batch>Y</use_batch>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1248</xloc>
|
||||
<yloc>448</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,869 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>checkpoint_job_citizen_appealing_violations_fz53</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/03 14:19:02.590</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/03 14:19:02.590</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Filter rows</from>
|
||||
<to>Abort</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow1.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow2.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow3.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow4.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow5.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow1.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow2.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow3.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow4.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow5.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Abort</name>
|
||||
<type>Abort</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<abort_option>ABORT_WITH_ERROR</abort_option>
|
||||
<always_log_rows>Y</always_log_rows>
|
||||
<row_threshold>0</row_threshold>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1264</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Dummy (do nothing)</name>
|
||||
<type>Dummy</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>352</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Filter rows</name>
|
||||
<type>FilterRows</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compare>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow2</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow3</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow4</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow5</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</compare>
|
||||
<send_true_to>Abort</send_true_to>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>944</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1264</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow1.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow1.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>432</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow2.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow2.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>512</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow3.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow3.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow4.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow4.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>672</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow5.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow5.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>752</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH status_check AS (
|
||||
SELECT
|
||||
bool_or(status = 'ERROR' AND job_name IN (
|
||||
'citizen_appealing_violations_fz53_flow1',
|
||||
'citizen_appealing_violations_fz53_flow2',
|
||||
'citizen_appealing_violations_fz53_flow3',
|
||||
'citizen_appealing_violations_fz53_flow4',
|
||||
'citizen_appealing_violations_fz53_flow5'
|
||||
)) AS has_error,
|
||||
count(*) FILTER (
|
||||
WHERE status = 'SUCCESS' AND job_name IN (
|
||||
'citizen_appealing_violations_fz53_flow1',
|
||||
'citizen_appealing_violations_fz53_flow2',
|
||||
'citizen_appealing_violations_fz53_flow3',
|
||||
'citizen_appealing_violations_fz53_flow4',
|
||||
'citizen_appealing_violations_fz53_flow5'
|
||||
)
|
||||
) = 5 AS all_success
|
||||
FROM public.etl_checkpoints
|
||||
)
|
||||
SELECT
|
||||
'job_citizen_appealing_violations_fz53' 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;</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>896</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,869 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>checkpoint_job_citizen_appealing_violations_fz53_delta</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/06/03 14:19:02.590</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/06/03 14:19:02.590</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Filter rows</from>
|
||||
<to>Abort</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow1.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow2.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow3.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow4.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>JSON input state_child_flow5.json</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow1.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow2.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow3.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow4.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Dummy (do nothing)</from>
|
||||
<to>JSON input state_child_flow5.json</to>
|
||||
<enabled>N</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Abort</name>
|
||||
<type>Abort</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<abort_option>ABORT_WITH_ERROR</abort_option>
|
||||
<always_log_rows>Y</always_log_rows>
|
||||
<row_threshold>0</row_threshold>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1264</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Dummy (do nothing)</name>
|
||||
<type>Dummy</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>352</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Filter rows</name>
|
||||
<type>FilterRows</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compare>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow2</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow3</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow4</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>child_flow5</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>status</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>AND</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>ERROR</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>OR</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>pipeline</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>recruits_info_flow1</text>
|
||||
<type>String</type>
|
||||
</value>
|
||||
</condition>
|
||||
</compare>
|
||||
<send_true_to>Abort</send_true_to>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>944</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>job_name</field>
|
||||
<name>job_name</name>
|
||||
</key>
|
||||
<schema>public</schema>
|
||||
<table>etl_checkpoints</table>
|
||||
<value>
|
||||
<name>job_name</name>
|
||||
<rename>job_name</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>record_created</name>
|
||||
<rename>record_created</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>status</name>
|
||||
<rename>status</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1264</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow1.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow1.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>432</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow2.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow2.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>512</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow3.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow3.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>592</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow4.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow4.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>672</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>JSON input state_child_flow5.json</name>
|
||||
<type>JsonInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<include>N</include>
|
||||
<include_field/>
|
||||
<rownum>N</rownum>
|
||||
<addresultfile>N</addresultfile>
|
||||
<readurl>N</readurl>
|
||||
<removeSourceField>N</removeSourceField>
|
||||
<IsIgnoreEmptyFile>N</IsIgnoreEmptyFile>
|
||||
<doNotFailIfNoFile>Y</doNotFailIfNoFile>
|
||||
<ignoreMissingPath>Y</ignoreMissingPath>
|
||||
<defaultPathLeafToNull>Y</defaultPathLeafToNull>
|
||||
<rownum_field/>
|
||||
<file>
|
||||
<name>${PROJECT_HOME}/info_recruits/citizen_tables/child/checkpoints/state_child_flow5.json</name>
|
||||
<filemask/>
|
||||
<exclude_filemask/>
|
||||
<file_required>N</file_required>
|
||||
<include_subfolders>N</include_subfolders>
|
||||
</file>
|
||||
<fields>
|
||||
<field>
|
||||
<name>pipeline</name>
|
||||
<path>$.pipeline</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
<field>
|
||||
<name>status</name>
|
||||
<path>$.status</path>
|
||||
<type>String</type>
|
||||
<format/>
|
||||
<currency/>
|
||||
<decimal/>
|
||||
<group/>
|
||||
<length>-1</length>
|
||||
<precision>-1</precision>
|
||||
<trim_type>none</trim_type>
|
||||
<repeat>N</repeat>
|
||||
</field>
|
||||
</fields>
|
||||
<limit>0</limit>
|
||||
<IsInFields>N</IsInFields>
|
||||
<IsAFile>N</IsAFile>
|
||||
<valueField/>
|
||||
<shortFileFieldName/>
|
||||
<pathFieldName/>
|
||||
<hiddenFieldName/>
|
||||
<lastModificationTimeFieldName/>
|
||||
<uriNameFieldName/>
|
||||
<rootUriNameFieldName/>
|
||||
<extensionFieldName/>
|
||||
<sizeFieldName/>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>752</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>WITH status_check AS (
|
||||
SELECT
|
||||
bool_or(status = 'ERROR' AND job_name IN (
|
||||
'delta_snils_inn_flow1',
|
||||
'delta_snils_inn_flow2',
|
||||
'delta_snils_inn_flow3',
|
||||
'delta_snils_inn_flow4',
|
||||
'delta_snils_inn_flow5'
|
||||
)) AS has_error,
|
||||
count(*) FILTER (
|
||||
WHERE status = 'SUCCESS' AND job_name IN (
|
||||
'delta_snils_inn_flow1',
|
||||
'delta_snils_inn_flow2',
|
||||
'delta_snils_inn_flow3',
|
||||
'delta_snils_inn_flow4',
|
||||
'delta_snils_inn_flow5'
|
||||
)
|
||||
) = 5 AS all_success
|
||||
FROM public.etl_checkpoints
|
||||
)
|
||||
SELECT
|
||||
'job_snils_inn_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;</sql>
|
||||
<variables_active>N</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>896</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -0,0 +1,362 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<workflow>
|
||||
<name>citizen_appealing_violations_fz53_job</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<workflow_version/>
|
||||
<workflow_status>0</workflow_status>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/08/05 12:45:28.561</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/08/05 12:45:28.561</modified_date>
|
||||
<parameters>
|
||||
<parameter>
|
||||
<name>COMMENT</name>
|
||||
<default_value> </default_value>
|
||||
<description/>
|
||||
</parameter>
|
||||
<parameter>
|
||||
<name>LIMIT_FW</name>
|
||||
<default_value>;</default_value>
|
||||
<description/>
|
||||
</parameter>
|
||||
<parameter>
|
||||
<name>M_R_CR_DATE</name>
|
||||
<default_value>3001-01-01 00:00:00</default_value>
|
||||
<description/>
|
||||
</parameter>
|
||||
<parameter>
|
||||
<name>M_R_UP_DATE</name>
|
||||
<default_value>0001-01-01 00:00:00</default_value>
|
||||
<description/>
|
||||
</parameter>
|
||||
</parameters>
|
||||
<actions>
|
||||
<action>
|
||||
<name>Start</name>
|
||||
<description/>
|
||||
<type>SPECIAL</type>
|
||||
<attributes/>
|
||||
<DayOfMonth>1</DayOfMonth>
|
||||
<hour>12</hour>
|
||||
<intervalMinutes>60</intervalMinutes>
|
||||
<intervalSeconds>0</intervalSeconds>
|
||||
<minutes>0</minutes>
|
||||
<repeat>N</repeat>
|
||||
<schedulerType>0</schedulerType>
|
||||
<weekDay>1</weekDay>
|
||||
<parallel>N</parallel>
|
||||
<xloc>96</xloc>
|
||||
<yloc>304</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>check_if_citizen_appealing_violations_fz53_job_exists.hpl</name>
|
||||
<description/>
|
||||
<type>PIPELINE</type>
|
||||
<attributes/>
|
||||
<add_date>N</add_date>
|
||||
<add_time>N</add_time>
|
||||
<clear_files>N</clear_files>
|
||||
<clear_rows>N</clear_rows>
|
||||
<create_parent_folder>N</create_parent_folder>
|
||||
<exec_per_row>N</exec_per_row>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/citizen_appealing_violations_fz53/checkpoints/check_if_citizen_appealing_violations_fz53_job_exists.hpl</filename>
|
||||
<loglevel>Basic</loglevel>
|
||||
<parameters>
|
||||
<pass_all_parameters>Y</pass_all_parameters>
|
||||
</parameters>
|
||||
<params_from_previous>N</params_from_previous>
|
||||
<run_configuration>local</run_configuration>
|
||||
<set_append_logfile>N</set_append_logfile>
|
||||
<set_logfile>N</set_logfile>
|
||||
<wait_until_finished>Y</wait_until_finished>
|
||||
<parallel>N</parallel>
|
||||
<xloc>416</xloc>
|
||||
<yloc>304</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>citizen_appealing_violations_fz53_job_exists_check</name>
|
||||
<description/>
|
||||
<type>SIMPLE_EVAL</type>
|
||||
<attributes/>
|
||||
<fieldtype>boolean</fieldtype>
|
||||
<successbooleancondition>false</successbooleancondition>
|
||||
<successcondition>equal</successcondition>
|
||||
<successnumbercondition>equal</successnumbercondition>
|
||||
<successwhenvarset>N</successwhenvarset>
|
||||
<valuetype>variable</valuetype>
|
||||
<variablename>JOB_EXECUTED_FLAG</variablename>
|
||||
<parallel>N</parallel>
|
||||
<xloc>832</xloc>
|
||||
<yloc>304</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>recruitments_five_flow.hpl</name>
|
||||
<description/>
|
||||
<type>PIPELINE</type>
|
||||
<attributes/>
|
||||
<add_date>N</add_date>
|
||||
<add_time>N</add_time>
|
||||
<clear_files>N</clear_files>
|
||||
<clear_rows>N</clear_rows>
|
||||
<create_parent_folder>N</create_parent_folder>
|
||||
<exec_per_row>N</exec_per_row>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/citizen_appealing_violations_fz53/recruitments_five_flow.hpl</filename>
|
||||
<loglevel>Basic</loglevel>
|
||||
<parameters>
|
||||
<pass_all_parameters>Y</pass_all_parameters>
|
||||
</parameters>
|
||||
<params_from_previous>N</params_from_previous>
|
||||
<run_configuration>local</run_configuration>
|
||||
<set_append_logfile>N</set_append_logfile>
|
||||
<set_logfile>N</set_logfile>
|
||||
<wait_until_finished>Y</wait_until_finished>
|
||||
<parallel>Y</parallel>
|
||||
<xloc>1296</xloc>
|
||||
<yloc>304</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>recruitment_five_flow_on_error.hpl</name>
|
||||
<description/>
|
||||
<type>PIPELINE</type>
|
||||
<attributes/>
|
||||
<add_date>N</add_date>
|
||||
<add_time>N</add_time>
|
||||
<clear_files>N</clear_files>
|
||||
<clear_rows>N</clear_rows>
|
||||
<create_parent_folder>N</create_parent_folder>
|
||||
<exec_per_row>N</exec_per_row>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/citizen_appealing_violations_fz53/recruitment_five_flow_on_error.hpl</filename>
|
||||
<logext/>
|
||||
<logfile/>
|
||||
<loglevel>Basic</loglevel>
|
||||
<parameters>
|
||||
<pass_all_parameters>Y</pass_all_parameters>
|
||||
</parameters>
|
||||
<params_from_previous>N</params_from_previous>
|
||||
<run_configuration>local</run_configuration>
|
||||
<set_append_logfile>N</set_append_logfile>
|
||||
<set_logfile>N</set_logfile>
|
||||
<wait_until_finished>Y</wait_until_finished>
|
||||
<parallel>N</parallel>
|
||||
<xloc>1296</xloc>
|
||||
<yloc>608</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>check_if_need_to_repeat_job.hpl</name>
|
||||
<description/>
|
||||
<type>PIPELINE</type>
|
||||
<attributes/>
|
||||
<add_date>N</add_date>
|
||||
<add_time>N</add_time>
|
||||
<clear_files>N</clear_files>
|
||||
<clear_rows>N</clear_rows>
|
||||
<create_parent_folder>N</create_parent_folder>
|
||||
<exec_per_row>N</exec_per_row>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/citizen_appealing_violations_fz53/check_if_need_to_repeat_job.hpl</filename>
|
||||
<loglevel>Basic</loglevel>
|
||||
<parameters>
|
||||
<pass_all_parameters>Y</pass_all_parameters>
|
||||
</parameters>
|
||||
<params_from_previous>N</params_from_previous>
|
||||
<run_configuration>local</run_configuration>
|
||||
<set_append_logfile>N</set_append_logfile>
|
||||
<set_logfile>N</set_logfile>
|
||||
<wait_until_finished>Y</wait_until_finished>
|
||||
<parallel>N</parallel>
|
||||
<xloc>832</xloc>
|
||||
<yloc>464</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>Simple evaluation</name>
|
||||
<description/>
|
||||
<type>SIMPLE_EVAL</type>
|
||||
<attributes/>
|
||||
<fieldtype>boolean</fieldtype>
|
||||
<successbooleancondition>true</successbooleancondition>
|
||||
<successcondition>equal</successcondition>
|
||||
<successnumbercondition>equal</successnumbercondition>
|
||||
<successwhenvarset>N</successwhenvarset>
|
||||
<valuetype>variable</valuetype>
|
||||
<variablename>NEED_TO_REPEAT_JOB</variablename>
|
||||
<parallel>N</parallel>
|
||||
<xloc>832</xloc>
|
||||
<yloc>608</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
<action>
|
||||
<name>recruitment_five_flow_delta.hpl</name>
|
||||
<description/>
|
||||
<type>PIPELINE</type>
|
||||
<attributes/>
|
||||
<add_date>N</add_date>
|
||||
<add_time>N</add_time>
|
||||
<clear_files>N</clear_files>
|
||||
<clear_rows>N</clear_rows>
|
||||
<create_parent_folder>N</create_parent_folder>
|
||||
<exec_per_row>N</exec_per_row>
|
||||
<filename>${PROJECT_HOME}/info_recruits/citizen_tables/citizen_appealing_violations_fz53/recruitment_five_flow_delta.hpl</filename>
|
||||
<logext/>
|
||||
<logfile/>
|
||||
<loglevel>Basic</loglevel>
|
||||
<parameters>
|
||||
<pass_all_parameters>Y</pass_all_parameters>
|
||||
</parameters>
|
||||
<params_from_previous>N</params_from_previous>
|
||||
<run_configuration>local</run_configuration>
|
||||
<set_append_logfile>N</set_append_logfile>
|
||||
<set_logfile>N</set_logfile>
|
||||
<wait_until_finished>Y</wait_until_finished>
|
||||
<parallel>N</parallel>
|
||||
<xloc>832</xloc>
|
||||
<yloc>800</yloc>
|
||||
<attributes_hac/>
|
||||
</action>
|
||||
</actions>
|
||||
<hops>
|
||||
<hop>
|
||||
<from>Start</from>
|
||||
<to>check_if_citizen_appealing_violations_fz53_job_exists.hpl</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>Y</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>check_if_citizen_appealing_violations_fz53_job_exists.hpl</from>
|
||||
<to>citizen_appealing_violations_fz53_job_exists_check</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>N</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>citizen_appealing_violations_fz53_job_exists_check</from>
|
||||
<to>recruitments_five_flow.hpl</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>N</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>citizen_appealing_violations_fz53_job_exists_check</from>
|
||||
<to>check_if_need_to_repeat_job.hpl</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>N</evaluation>
|
||||
<unconditional>N</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>check_if_need_to_repeat_job.hpl</from>
|
||||
<to>Simple evaluation</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>N</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Simple evaluation</from>
|
||||
<to>recruitment_five_flow_on_error.hpl</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>Y</evaluation>
|
||||
<unconditional>N</unconditional>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Simple evaluation</from>
|
||||
<to>recruitment_five_flow_delta.hpl</to>
|
||||
<enabled>Y</enabled>
|
||||
<evaluation>N</evaluation>
|
||||
<unconditional>N</unconditional>
|
||||
</hop>
|
||||
</hops>
|
||||
<notepads>
|
||||
<notepad>
|
||||
<backgroundcolorblue>251</backgroundcolorblue>
|
||||
<backgroundcolorgreen>232</backgroundcolorgreen>
|
||||
<backgroundcolorred>201</backgroundcolorred>
|
||||
<bordercolorblue>90</bordercolorblue>
|
||||
<bordercolorgreen>58</bordercolorgreen>
|
||||
<bordercolorred>14</bordercolorred>
|
||||
<fontbold>N</fontbold>
|
||||
<fontcolorblue>90</fontcolorblue>
|
||||
<fontcolorgreen>58</fontcolorgreen>
|
||||
<fontcolorred>14</fontcolorred>
|
||||
<fontitalic>N</fontitalic>
|
||||
<fontsize>-1</fontsize>
|
||||
<height>26</height>
|
||||
<xloc>944</xloc>
|
||||
<yloc>256</yloc>
|
||||
<note>Первичка</note>
|
||||
<width>65</width>
|
||||
</notepad>
|
||||
<notepad>
|
||||
<backgroundcolorblue>251</backgroundcolorblue>
|
||||
<backgroundcolorgreen>232</backgroundcolorgreen>
|
||||
<backgroundcolorred>201</backgroundcolorred>
|
||||
<bordercolorblue>90</bordercolorblue>
|
||||
<bordercolorgreen>58</bordercolorgreen>
|
||||
<bordercolorred>14</bordercolorred>
|
||||
<fontbold>N</fontbold>
|
||||
<fontcolorblue>90</fontcolorblue>
|
||||
<fontcolorgreen>58</fontcolorgreen>
|
||||
<fontcolorred>14</fontcolorred>
|
||||
<fontitalic>N</fontitalic>
|
||||
<fontsize>-1</fontsize>
|
||||
<height>26</height>
|
||||
<xloc>944</xloc>
|
||||
<yloc>560</yloc>
|
||||
<note>Повторка</note>
|
||||
<width>64</width>
|
||||
</notepad>
|
||||
<notepad>
|
||||
<backgroundcolorblue>251</backgroundcolorblue>
|
||||
<backgroundcolorgreen>232</backgroundcolorgreen>
|
||||
<backgroundcolorred>201</backgroundcolorred>
|
||||
<bordercolorblue>90</bordercolorblue>
|
||||
<bordercolorgreen>58</bordercolorgreen>
|
||||
<bordercolorred>14</bordercolorred>
|
||||
<fontbold>N</fontbold>
|
||||
<fontcolorblue>90</fontcolorblue>
|
||||
<fontcolorgreen>58</fontcolorgreen>
|
||||
<fontcolorred>14</fontcolorred>
|
||||
<fontitalic>N</fontitalic>
|
||||
<fontsize>-1</fontsize>
|
||||
<height>26</height>
|
||||
<xloc>752</xloc>
|
||||
<yloc>720</yloc>
|
||||
<note>Дельта</note>
|
||||
<width>49</width>
|
||||
</notepad>
|
||||
<notepad>
|
||||
<backgroundcolorblue>251</backgroundcolorblue>
|
||||
<backgroundcolorgreen>232</backgroundcolorgreen>
|
||||
<backgroundcolorred>201</backgroundcolorred>
|
||||
<bordercolorblue>90</bordercolorblue>
|
||||
<bordercolorgreen>58</bordercolorgreen>
|
||||
<bordercolorred>14</bordercolorred>
|
||||
<fontbold>N</fontbold>
|
||||
<fontcolorblue>90</fontcolorblue>
|
||||
<fontcolorgreen>58</fontcolorgreen>
|
||||
<fontcolorred>14</fontcolorred>
|
||||
<fontitalic>N</fontitalic>
|
||||
<fontname>Segoe UI</fontname>
|
||||
<fontsize>9</fontsize>
|
||||
<height>150</height>
|
||||
<xloc>1200</xloc>
|
||||
<yloc>80</yloc>
|
||||
<note>citizen_appealing_violations_fz53_job
|
||||
|
||||
M_R_UP_DATE
|
||||
|
||||
M_R_CR_DATE
|
||||
|
||||
0001-01-01 00:00:00
|
||||
|
||||
3001-01-01 00:00:00</note>
|
||||
<width>206</width>
|
||||
</notepad>
|
||||
</notepads>
|
||||
<attributes/>
|
||||
</workflow>
|
||||
File diff suppressed because it is too large
Load diff
|
|
@ -0,0 +1,521 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>citizen_appealing_violations_fz53_flow</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/08/05 14:31:22.799</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/08/05 14:31:22.799</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Create job execution record</from>
|
||||
<to>Table input</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Filter rows</from>
|
||||
<to>Change job status on success</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Detect empty stream</from>
|
||||
<to>Change job status on success</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Change job status on error</from>
|
||||
<to>Abort</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table output</from>
|
||||
<to>Change job status on error</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Table output</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Group by</from>
|
||||
<to>Identify last row in a stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Identify last row in a stream</from>
|
||||
<to>User defined Java expression</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>User defined Java expression</from>
|
||||
<to>Update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table output</from>
|
||||
<to>Group by</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update</from>
|
||||
<to>Change job status on error</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update</from>
|
||||
<to>Detect empty stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Abort</name>
|
||||
<type>Abort</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<abort_option>ABORT_WITH_ERROR</abort_option>
|
||||
<always_log_rows>Y</always_log_rows>
|
||||
<row_threshold>0</row_threshold>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1472</xloc>
|
||||
<yloc>832</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on error</name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
<argument>
|
||||
<name>error_description</name>
|
||||
</argument>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>Y</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET status = 'ERROR',
|
||||
error_description = ?
|
||||
WHERE job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1472</xloc>
|
||||
<yloc>656</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on success</name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>N</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET status = 'SUCCESS'
|
||||
WHERE job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1952</xloc>
|
||||
<yloc>512</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Create job execution record</name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>N</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>INSERT INTO etl.job_execution (id, job_name, status, execution_datetime, error_description, recruitment_id)
|
||||
VALUES (DEFAULT, '${JOB_NAME}', 'PROCESSING', DEFAULT, null, '${IDM_ID}');
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>432</xloc>
|
||||
<yloc>656</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Detect empty stream</name>
|
||||
<type>DetectEmptyStream</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1696</xloc>
|
||||
<yloc>512</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Filter rows</name>
|
||||
<type>FilterRows</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compare>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>last_row</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>Y</text>
|
||||
<type>Boolean</type>
|
||||
</value>
|
||||
</condition>
|
||||
</compare>
|
||||
<send_true_to>Change job status on success</send_true_to>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1696</xloc>
|
||||
<yloc>608</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Group by</name>
|
||||
<type>GroupBy</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<add_linenr>N</add_linenr>
|
||||
<all_rows>N</all_rows>
|
||||
<directory>${java.io.tmpdir}</directory>
|
||||
<fields>
|
||||
<field>
|
||||
<aggregate>has_appealing_violations_fz53_raw</aggregate>
|
||||
<subject>is_appealing_violations_fz53</subject>
|
||||
<type>MAX</type>
|
||||
<valuefield/>
|
||||
</field>
|
||||
</fields>
|
||||
<give_back_row>N</give_back_row>
|
||||
<group>
|
||||
<field>
|
||||
<name>recruit_id</name>
|
||||
</field>
|
||||
</group>
|
||||
<ignore_aggregate>N</ignore_aggregate>
|
||||
<linenr_fieldname/>
|
||||
<prefix>grp</prefix>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>832</xloc>
|
||||
<yloc>512</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Identify last row in a stream</name>
|
||||
<type>DetectLastRow</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<resultfieldname>last_row</resultfieldname>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1024</xloc>
|
||||
<yloc>512</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>postgres.decision-document-service</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<sql>SELECT
|
||||
ad.recruit_id,
|
||||
ad.create_date, -- дата создания обжалования
|
||||
ad.appeal_number AS number_appealed, -- номер обжалуемого решения
|
||||
ad.appeal_date AS date_appealed, -- дата обжалуемого решения
|
||||
ad.result_number AS case_number, -- номер принятого решения
|
||||
ad.result_date AS decision_date, -- дата принятия решения
|
||||
CASE
|
||||
WHEN ad.result = '1' THEN 'Удовлетворена'
|
||||
WHEN ad.result = '2' THEN 'Частично удовлетворена'
|
||||
WHEN ad.result = '3' THEN 'Отказано в удовлетворении'
|
||||
ELSE NULL
|
||||
END AS result_appeal, -- код рассмотрения
|
||||
ad.commission_name AS name_commission, -- наименование комиссии, принявшей решение
|
||||
ad.reason_for_add_entry AS grounds, -- основание для внесения записи
|
||||
ad.hidden,
|
||||
CASE
|
||||
WHEN ad.hidden is false THEN 1
|
||||
ELSE 0
|
||||
END AS is_appealing_violations_fz53
|
||||
FROM public.appeal_document_dto ad
|
||||
JOIN public.recruit r ON r.id = ad.recruit_id AND '${IDM_ID}' != '' -- Проверка на пустую строку
|
||||
AND COALESCE(r.current_recruitment, r.target_recruitment) = '${IDM_ID}'
|
||||
AND '${M_R_CR_DATE}' >= ad.create_date
|
||||
--AND '${INFRINGEMENT_DATE}'::timestamp <= coalesce(ad.updated_at, ad.created_at) -- для дельты
|
||||
--WHERE hidden IS FALSE
|
||||
|
||||
${LIMIT_FW}</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>640</xloc>
|
||||
<yloc>656</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table output</name>
|
||||
<type>TableOutput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>1000</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<fields>
|
||||
<field>
|
||||
<column_name>recruit_id</column_name>
|
||||
<stream_name>recruit_id</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>create_date</column_name>
|
||||
<stream_name>create_date</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>number_appealed</column_name>
|
||||
<stream_name>number_appealed</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>date_appealed</column_name>
|
||||
<stream_name>date_appealed</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>case_number</column_name>
|
||||
<stream_name>case_number</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>decision_date</column_name>
|
||||
<stream_name>decision_date</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>result_appeal</column_name>
|
||||
<stream_name>result_appeal</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>name_commission</column_name>
|
||||
<stream_name>name_commission</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>grounds</column_name>
|
||||
<stream_name>grounds</stream_name>
|
||||
</field>
|
||||
<field>
|
||||
<column_name>hidden</column_name>
|
||||
<stream_name>hidden</stream_name>
|
||||
</field>
|
||||
</fields>
|
||||
<ignore_errors>N</ignore_errors>
|
||||
<only_when_have_rows>N</only_when_have_rows>
|
||||
<partitioning_daily>N</partitioning_daily>
|
||||
<partitioning_enabled>N</partitioning_enabled>
|
||||
<partitioning_monthly>Y</partitioning_monthly>
|
||||
<return_keys>N</return_keys>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<specify_fields>Y</specify_fields>
|
||||
<table>citizen_appealing_violations_fz53</table>
|
||||
<tablename_in_field>N</tablename_in_field>
|
||||
<tablename_in_table>Y</tablename_in_table>
|
||||
<truncate>N</truncate>
|
||||
<use_batch>Y</use_batch>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>832</xloc>
|
||||
<yloc>656</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Update</name>
|
||||
<type>Update</type>
|
||||
<description/>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<error_ignored>Y</error_ignored>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen</table>
|
||||
<value>
|
||||
<name>has_appealing_violations_fz53</name>
|
||||
<rename>has_appealing_violations_fz53</rename>
|
||||
</value>
|
||||
</lookup>
|
||||
<skip_lookup>N</skip_lookup>
|
||||
<use_batch>Y</use_batch>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1472</xloc>
|
||||
<yloc>512</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>User defined Java expression</name>
|
||||
<type>Janino</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<formula>
|
||||
<field_name>has_appealing_violations_fz53</field_name>
|
||||
<formula_string>has_appealing_violations_fz53_raw == 1</formula_string>
|
||||
<value_type>Boolean</value_type>
|
||||
<value_length>-1</value_length>
|
||||
<value_precision>-1</value_precision>
|
||||
<replace_field/>
|
||||
</formula>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1248</xloc>
|
||||
<yloc>512</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
<error>
|
||||
<source_transform>Table output</source_transform>
|
||||
<target_transform>Change job status on error</target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename>error_description</descriptions_valuename>
|
||||
<fields_valuename/>
|
||||
<codes_valuename>error_code</codes_valuename>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
<error>
|
||||
<source_transform>Update</source_transform>
|
||||
<target_transform>Change job status on error</target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename/>
|
||||
<fields_valuename/>
|
||||
<codes_valuename/>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,161 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>citizen_appealing_violations_fz53_flow1</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<pipeline_status>0</pipeline_status>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/05/21 14:05:02.260</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/05/21 14:05:02.260</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT
|
||||
ad.recruit_id,
|
||||
ad.create_date, -- дата создания обжалования
|
||||
ad.appeal_number AS number_appealed, -- номер обжалуемого решения
|
||||
ad.appeal_date AS date_appealed, -- дата обжалуемого решения
|
||||
ad.result_number AS case_number, -- номер принятого решения
|
||||
ad.result_date AS decision_date, -- дата принятия решения
|
||||
CASE
|
||||
WHEN ad.result = '1' THEN 'Удовлетворена'
|
||||
WHEN ad.result = '2' THEN 'Частично удовлетворена'
|
||||
WHEN ad.result = '3' THEN 'Отказано в удовлетворении'
|
||||
ELSE NULL
|
||||
END AS result_appeal, -- код рассмотрения
|
||||
ad.commission_name AS name_commission, -- наименование комиссии, принявшей решение
|
||||
ad.reason_for_add_entry AS grounds, -- основание для внесения записи
|
||||
ad.hidden --has_appealing_violations_fz53
|
||||
FROM public.appeal_document_dto ad
|
||||
JOIN public.recruit r ON r.id = ad.recruit_id AND '${ID_F1}' != '' -- Проверка на пустую строку
|
||||
AND COALESCE(r.current_recruitment, r.target_recruitment) = '${ID_F1}'
|
||||
--AND '${INFRINGEMENT_DATE}'::timestamp <= coalesce(ad.updated_at, ad.created_at) -- для дельты
|
||||
--WHERE hidden IS FALSE</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>448</xloc>
|
||||
<yloc>288</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
<name2/>
|
||||
</key>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>create_date</field>
|
||||
<name>create_date</name>
|
||||
<name2/>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_appealing_violations_fz53</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>create_date</name>
|
||||
<rename>create_date</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>number_appealed</name>
|
||||
<rename>number_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>date_appealed</name>
|
||||
<rename>date_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>case_number</name>
|
||||
<rename>case_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>decision_date</name>
|
||||
<rename>decision_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>result_appeal</name>
|
||||
<rename>result_appeal</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>name_commission</name>
|
||||
<rename>name_commission</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>grounds</name>
|
||||
<rename>grounds</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>hidden</name>
|
||||
<rename>hidden</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>864</xloc>
|
||||
<yloc>288</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,158 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>citizen_appealing_violations_fz53_flow2</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/05/21 14:05:02.260</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/05/21 14:05:02.260</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>create_date</field>
|
||||
<name>create_date</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_appealing_violations_fz53</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>create_date</name>
|
||||
<rename>create_date</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>number_appealed</name>
|
||||
<rename>number_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>date_appealed</name>
|
||||
<rename>date_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>case_number</name>
|
||||
<rename>case_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>decision_date</name>
|
||||
<rename>decision_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>result_appeal</name>
|
||||
<rename>result_appeal</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>name_commission</name>
|
||||
<rename>name_commission</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>grounds</name>
|
||||
<rename>grounds</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>hidden</name>
|
||||
<rename>hidden</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>928</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT
|
||||
ad.recruit_id,
|
||||
ad.create_date, -- дата создания обжалования
|
||||
ad.appeal_number AS number_appealed, -- номер обжалуемого решения
|
||||
ad.appeal_date AS date_appealed, -- дата обжалуемого решения
|
||||
ad.result_number AS case_number, -- номер принятого решения
|
||||
ad.result_date AS decision_date, -- дата принятия решения
|
||||
CASE
|
||||
WHEN ad.result = '1' THEN 'Удовлетворена'
|
||||
WHEN ad.result = '2' THEN 'Частично удовлетворена'
|
||||
WHEN ad.result = '3' THEN 'Отказано в удовлетворении'
|
||||
ELSE NULL
|
||||
END AS result_appeal, -- код рассмотрения
|
||||
ad.commission_name AS name_commission, -- наименование комиссии, принявшей решение
|
||||
ad.reason_for_add_entry AS grounds, -- основание для внесения записи
|
||||
ad.hidden --has_appealing_violations_fz53
|
||||
FROM public.appeal_document_dto ad
|
||||
JOIN public.recruit r ON r.id = ad.recruit_id AND '${ID_F2}' != '' -- Проверка на пустую строку
|
||||
AND COALESCE(r.current_recruitment, r.target_recruitment) = '${ID_F2}'
|
||||
--AND '${INFRINGEMENT_DATE}'::timestamp <= coalesce(ad.updated_at, ad.created_at) -- для дельты
|
||||
--WHERE hidden IS FALSE</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>512</xloc>
|
||||
<yloc>304</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,158 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>citizen_appealing_violations_fz53_flow3</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/05/21 14:05:02.260</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/05/21 14:05:02.260</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>create_date</field>
|
||||
<name>create_date</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_appealing_violations_fz53</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>create_date</name>
|
||||
<rename>create_date</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>number_appealed</name>
|
||||
<rename>number_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>date_appealed</name>
|
||||
<rename>date_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>case_number</name>
|
||||
<rename>case_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>decision_date</name>
|
||||
<rename>decision_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>result_appeal</name>
|
||||
<rename>result_appeal</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>name_commission</name>
|
||||
<rename>name_commission</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>grounds</name>
|
||||
<rename>grounds</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>hidden</name>
|
||||
<rename>hidden</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>992</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT
|
||||
ad.recruit_id,
|
||||
ad.create_date, -- дата создания обжалования
|
||||
ad.appeal_number AS number_appealed, -- номер обжалуемого решения
|
||||
ad.appeal_date AS date_appealed, -- дата обжалуемого решения
|
||||
ad.result_number AS case_number, -- номер принятого решения
|
||||
ad.result_date AS decision_date, -- дата принятия решения
|
||||
CASE
|
||||
WHEN ad.result = '1' THEN 'Удовлетворена'
|
||||
WHEN ad.result = '2' THEN 'Частично удовлетворена'
|
||||
WHEN ad.result = '3' THEN 'Отказано в удовлетворении'
|
||||
ELSE NULL
|
||||
END AS result_appeal, -- код рассмотрения
|
||||
ad.commission_name AS name_commission, -- наименование комиссии, принявшей решение
|
||||
ad.reason_for_add_entry AS grounds, -- основание для внесения записи
|
||||
ad.hidden --has_appealing_violations_fz53
|
||||
FROM public.appeal_document_dto ad
|
||||
JOIN public.recruit r ON r.id = ad.recruit_id AND '${ID_F3}' != '' -- Проверка на пустую строку
|
||||
AND COALESCE(r.current_recruitment, r.target_recruitment) = '${ID_F3}'
|
||||
--AND '${INFRINGEMENT_DATE}'::timestamp <= coalesce(ad.updated_at, ad.created_at) -- для дельты
|
||||
--WHERE hidden IS FALSE</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>576</xloc>
|
||||
<yloc>400</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,158 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>citizen_appealing_violations_fz53_flow4</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/05/21 14:05:02.260</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/05/21 14:05:02.260</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>create_date</field>
|
||||
<name>create_date</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_appealing_violations_fz53</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>create_date</name>
|
||||
<rename>create_date</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>number_appealed</name>
|
||||
<rename>number_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>date_appealed</name>
|
||||
<rename>date_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>case_number</name>
|
||||
<rename>case_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>decision_date</name>
|
||||
<rename>decision_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>result_appeal</name>
|
||||
<rename>result_appeal</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>name_commission</name>
|
||||
<rename>name_commission</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>grounds</name>
|
||||
<rename>grounds</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>hidden</name>
|
||||
<rename>hidden</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>896</xloc>
|
||||
<yloc>368</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT
|
||||
ad.recruit_id,
|
||||
ad.create_date, -- дата создания обжалования
|
||||
ad.appeal_number AS number_appealed, -- номер обжалуемого решения
|
||||
ad.appeal_date AS date_appealed, -- дата обжалуемого решения
|
||||
ad.result_number AS case_number, -- номер принятого решения
|
||||
ad.result_date AS decision_date, -- дата принятия решения
|
||||
CASE
|
||||
WHEN ad.result = '1' THEN 'Удовлетворена'
|
||||
WHEN ad.result = '2' THEN 'Частично удовлетворена'
|
||||
WHEN ad.result = '3' THEN 'Отказано в удовлетворении'
|
||||
ELSE NULL
|
||||
END AS result_appeal, -- код рассмотрения
|
||||
ad.commission_name AS name_commission, -- наименование комиссии, принявшей решение
|
||||
ad.reason_for_add_entry AS grounds, -- основание для внесения записи
|
||||
ad.hidden --has_appealing_violations_fz53
|
||||
FROM public.appeal_document_dto ad
|
||||
JOIN public.recruit r ON r.id = ad.recruit_id AND '${ID_F4}' != '' -- Проверка на пустую строку
|
||||
AND COALESCE(r.current_recruitment, r.target_recruitment) = '${ID_F4}'
|
||||
--AND '${INFRINGEMENT_DATE}'::timestamp <= coalesce(ad.updated_at, ad.created_at) -- для дельты
|
||||
--WHERE hidden IS FALSE</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>480</xloc>
|
||||
<yloc>368</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -1,158 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>citizen_appealing_violations_fz53_flow5</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/05/21 14:05:02.260</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/05/21 14:05:02.260</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>create_date</field>
|
||||
<name>create_date</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_appealing_violations_fz53</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>create_date</name>
|
||||
<rename>create_date</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>number_appealed</name>
|
||||
<rename>number_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>date_appealed</name>
|
||||
<rename>date_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>case_number</name>
|
||||
<rename>case_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>decision_date</name>
|
||||
<rename>decision_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>result_appeal</name>
|
||||
<rename>result_appeal</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>name_commission</name>
|
||||
<rename>name_commission</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>grounds</name>
|
||||
<rename>grounds</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>hidden</name>
|
||||
<rename>hidden</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1104</xloc>
|
||||
<yloc>368</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<limit>0</limit>
|
||||
<sql>SELECT
|
||||
ad.recruit_id,
|
||||
ad.create_date, -- дата создания обжалования
|
||||
ad.appeal_number AS number_appealed, -- номер обжалуемого решения
|
||||
ad.appeal_date AS date_appealed, -- дата обжалуемого решения
|
||||
ad.result_number AS case_number, -- номер принятого решения
|
||||
ad.result_date AS decision_date, -- дата принятия решения
|
||||
CASE
|
||||
WHEN ad.result = '1' THEN 'Удовлетворена'
|
||||
WHEN ad.result = '2' THEN 'Частично удовлетворена'
|
||||
WHEN ad.result = '3' THEN 'Отказано в удовлетворении'
|
||||
ELSE NULL
|
||||
END AS result_appeal, -- код рассмотрения
|
||||
ad.commission_name AS name_commission, -- наименование комиссии, принявшей решение
|
||||
ad.reason_for_add_entry AS grounds, -- основание для внесения записи
|
||||
ad.hidden --has_appealing_violations_fz53
|
||||
FROM public.appeal_document_dto ad
|
||||
JOIN public.recruit r ON r.id = ad.recruit_id AND '${ID_F5}' != '' -- Проверка на пустую строку
|
||||
AND COALESCE(r.current_recruitment, r.target_recruitment) = '${ID_F5}'
|
||||
--AND '${INFRINGEMENT_DATE}'::timestamp <= coalesce(ad.updated_at, ad.created_at) -- для дельты
|
||||
--WHERE hidden IS FALSE</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>368</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -0,0 +1,532 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>citizen_appealing_violations_fz53_flow_delta</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/08/11 13:22:56.048</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/08/11 13:22:56.048</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Create job execution record</from>
|
||||
<to>Table input</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Detect empty stream</from>
|
||||
<to>Change job status on success</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Filter rows</from>
|
||||
<to>Change job status on success</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Change job status on error</from>
|
||||
<to>Abort</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Insert / update</from>
|
||||
<to>Change job status on error</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Group by</from>
|
||||
<to>Identify last row in a stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Identify last row in a stream</from>
|
||||
<to>User defined Java expression</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>User defined Java expression</from>
|
||||
<to>Update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Insert / update</from>
|
||||
<to>Group by</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update</from>
|
||||
<to>Change job status on error</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update</from>
|
||||
<to>Detect empty stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Abort</name>
|
||||
<type>Abort</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<abort_option>ABORT_WITH_ERROR</abort_option>
|
||||
<always_log_rows>Y</always_log_rows>
|
||||
<row_threshold>0</row_threshold>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1360</xloc>
|
||||
<yloc>384</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on error</name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
<argument>
|
||||
<name>error_description</name>
|
||||
</argument>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>Y</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET status = 'DELTA_ERROR',
|
||||
error_description = ?
|
||||
WHERE job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1360</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on success</name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>N</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET status = 'DELTA_SUCCESS'
|
||||
WHERE job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1728</xloc>
|
||||
<yloc>144</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Create job execution record</name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>N</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET
|
||||
status = 'DELTA_PROCESSING',
|
||||
execution_datetime = DEFAULT,
|
||||
error_description = NULL
|
||||
where job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>336</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Detect empty stream</name>
|
||||
<type>DetectEmptyStream</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1552</xloc>
|
||||
<yloc>64</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Filter rows</name>
|
||||
<type>FilterRows</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compare>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>last_row</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>Y</text>
|
||||
<type>Boolean</type>
|
||||
</value>
|
||||
</condition>
|
||||
</compare>
|
||||
<send_true_to>Change job status on success</send_true_to>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1472</xloc>
|
||||
<yloc>144</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Group by</name>
|
||||
<type>GroupBy</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<add_linenr>N</add_linenr>
|
||||
<all_rows>N</all_rows>
|
||||
<directory>${java.io.tmpdir}</directory>
|
||||
<fields>
|
||||
<field>
|
||||
<aggregate>has_appealing_violations_fz53_raw</aggregate>
|
||||
<subject>is_appealing_violations_fz53</subject>
|
||||
<type>MAX</type>
|
||||
</field>
|
||||
</fields>
|
||||
<give_back_row>N</give_back_row>
|
||||
<group>
|
||||
<field>
|
||||
<name>recruit_id</name>
|
||||
</field>
|
||||
</group>
|
||||
<ignore_aggregate>N</ignore_aggregate>
|
||||
<prefix>grp</prefix>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>720</xloc>
|
||||
<yloc>64</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Identify last row in a stream</name>
|
||||
<type>DetectLastRow</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<resultfieldname>last_row</resultfieldname>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>912</xloc>
|
||||
<yloc>64</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>create_date</field>
|
||||
<name>create_date</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_appealing_violations_fz53</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>create_date</name>
|
||||
<rename>create_date</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>number_appealed</name>
|
||||
<rename>number_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>date_appealed</name>
|
||||
<rename>date_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>case_number</name>
|
||||
<rename>case_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>decision_date</name>
|
||||
<rename>decision_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>result_appeal</name>
|
||||
<rename>result_appeal</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>name_commission</name>
|
||||
<rename>name_commission</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>grounds</name>
|
||||
<rename>grounds</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>hidden</name>
|
||||
<rename>hidden</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>720</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>postgres.decision-document-service</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<sql>SELECT
|
||||
ad.recruit_id,
|
||||
ad.create_date, -- дата создания обжалования
|
||||
ad.appeal_number AS number_appealed, -- номер обжалуемого решения
|
||||
ad.appeal_date AS date_appealed, -- дата обжалуемого решения
|
||||
ad.result_number AS case_number, -- номер принятого решения
|
||||
ad.result_date AS decision_date, -- дата принятия решения
|
||||
CASE
|
||||
WHEN ad.result = '1' THEN 'Удовлетворена'
|
||||
WHEN ad.result = '2' THEN 'Частично удовлетворена'
|
||||
WHEN ad.result = '3' THEN 'Отказано в удовлетворении'
|
||||
ELSE NULL
|
||||
END AS result_appeal, -- код рассмотрения
|
||||
ad.commission_name AS name_commission, -- наименование комиссии, принявшей решение
|
||||
ad.reason_for_add_entry AS grounds, -- основание для внесения записи
|
||||
ad.hidden,
|
||||
CASE
|
||||
WHEN ad.hidden is false THEN 1
|
||||
ELSE 0
|
||||
END AS is_appealing_violations_fz53
|
||||
FROM public.appeal_document_dto ad
|
||||
JOIN public.recruit r ON r.id = ad.recruit_id AND '${IDM_ID}' != '' -- Проверка на пустую строку
|
||||
AND COALESCE(r.current_recruitment, r.target_recruitment) = '${IDM_ID}'
|
||||
AND ad.create_date >= '${M_R_UP_DATE}'::timestamp
|
||||
--AND '${INFRINGEMENT_DATE}'::timestamp <= coalesce(ad.updated_at, ad.created_at) -- для дельты
|
||||
--WHERE hidden IS FALSE
|
||||
|
||||
${LIMIT_FW}</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>544</xloc>
|
||||
<yloc>224</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Update</name>
|
||||
<type>Update</type>
|
||||
<description/>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<error_ignored>Y</error_ignored>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen</table>
|
||||
<value>
|
||||
<name>has_appealing_violations_fz53</name>
|
||||
<rename>has_appealing_violations_fz53</rename>
|
||||
</value>
|
||||
</lookup>
|
||||
<skip_lookup>N</skip_lookup>
|
||||
<use_batch>Y</use_batch>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1360</xloc>
|
||||
<yloc>64</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>User defined Java expression</name>
|
||||
<type>Janino</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<formula>
|
||||
<field_name>has_appealing_violations_fz53</field_name>
|
||||
<formula_string>has_appealing_violations_fz53_raw == 1</formula_string>
|
||||
<value_type>Boolean</value_type>
|
||||
<value_length>-1</value_length>
|
||||
<value_precision>-1</value_precision>
|
||||
<replace_field/>
|
||||
</formula>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1136</xloc>
|
||||
<yloc>64</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
<error>
|
||||
<source_transform>Insert / update</source_transform>
|
||||
<target_transform>Change job status on error</target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename/>
|
||||
<fields_valuename/>
|
||||
<codes_valuename/>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
<error>
|
||||
<source_transform>Update</source_transform>
|
||||
<target_transform>Change job status on error</target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename/>
|
||||
<fields_valuename/>
|
||||
<codes_valuename/>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
|
|
@ -0,0 +1,547 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pipeline>
|
||||
<info>
|
||||
<name>citizen_appealing_violations_fz53_flow_repeat</name>
|
||||
<name_sync_with_filename>Y</name_sync_with_filename>
|
||||
<description/>
|
||||
<extended_description/>
|
||||
<pipeline_version/>
|
||||
<pipeline_type>Normal</pipeline_type>
|
||||
<parameters>
|
||||
</parameters>
|
||||
<capture_transform_performance>N</capture_transform_performance>
|
||||
<transform_performance_capturing_delay>1000</transform_performance_capturing_delay>
|
||||
<transform_performance_capturing_size_limit>100</transform_performance_capturing_size_limit>
|
||||
<created_user>-</created_user>
|
||||
<created_date>2025/08/08 13:25:52.319</created_date>
|
||||
<modified_user>-</modified_user>
|
||||
<modified_date>2025/08/08 13:25:52.319</modified_date>
|
||||
</info>
|
||||
<notepads>
|
||||
</notepads>
|
||||
<order>
|
||||
<hop>
|
||||
<from>Create job execution record</from>
|
||||
<to>Table input</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Filter rows</from>
|
||||
<to>Change job status on success</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Detect empty stream</from>
|
||||
<to>Change job status on success</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Change job status on error</from>
|
||||
<to>Abort</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Insert / update</from>
|
||||
<to>Change job status on error</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Table input</from>
|
||||
<to>Insert / update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Group by</from>
|
||||
<to>Identify last row in a stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Identify last row in a stream</from>
|
||||
<to>User defined Java expression</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>User defined Java expression</from>
|
||||
<to>Update</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Insert / update</from>
|
||||
<to>Group by</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update</from>
|
||||
<to>Change job status on error</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update</from>
|
||||
<to>Filter rows</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
<hop>
|
||||
<from>Update</from>
|
||||
<to>Detect empty stream</to>
|
||||
<enabled>Y</enabled>
|
||||
</hop>
|
||||
</order>
|
||||
<transform>
|
||||
<name>Abort</name>
|
||||
<type>Abort</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<abort_option>ABORT_WITH_ERROR</abort_option>
|
||||
<always_log_rows>Y</always_log_rows>
|
||||
<row_threshold>0</row_threshold>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1328</xloc>
|
||||
<yloc>368</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on error</name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
<argument>
|
||||
<name>error_description</name>
|
||||
</argument>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>Y</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET status = 'ERROR',
|
||||
error_description = ?
|
||||
WHERE job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1328</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Change job status on success</name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>Y</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>N</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>UPDATE etl.job_execution
|
||||
SET status = 'SUCCESS'
|
||||
WHERE job_name = '${JOB_NAME}'
|
||||
and recruitment_id = '${IDM_ID}';
|
||||
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1792</xloc>
|
||||
<yloc>80</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Create job execution record</name>
|
||||
<type>ExecSql</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<arguments>
|
||||
</arguments>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<quoteString>N</quoteString>
|
||||
<replace_variables>Y</replace_variables>
|
||||
<set_params>N</set_params>
|
||||
<single_statement>N</single_statement>
|
||||
<sql>INSERT INTO etl.job_execution (
|
||||
id,
|
||||
job_name,
|
||||
status,
|
||||
execution_datetime,
|
||||
error_description,
|
||||
recruitment_id
|
||||
)
|
||||
VALUES (
|
||||
DEFAULT,
|
||||
'${JOB_NAME}',
|
||||
'PROCESSING',
|
||||
DEFAULT,
|
||||
NULL,
|
||||
'${IDM_ID}'
|
||||
)
|
||||
ON CONFLICT (job_name, recruitment_id)
|
||||
DO UPDATE SET
|
||||
status = 'PROCESSING',
|
||||
execution_datetime = DEFAULT,
|
||||
error_description = NULL
|
||||
</sql>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>272</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Detect empty stream</name>
|
||||
<type>DetectEmptyStream</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1520</xloc>
|
||||
<yloc>80</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Filter rows</name>
|
||||
<type>FilterRows</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compare>
|
||||
<condition>
|
||||
<conditions>
|
||||
</conditions>
|
||||
<function>=</function>
|
||||
<leftvalue>last_row</leftvalue>
|
||||
<negated>N</negated>
|
||||
<operator>-</operator>
|
||||
<value>
|
||||
<isnull>N</isnull>
|
||||
<length>-1</length>
|
||||
<name>constant</name>
|
||||
<precision>-1</precision>
|
||||
<text>Y</text>
|
||||
<type>Boolean</type>
|
||||
</value>
|
||||
</condition>
|
||||
</compare>
|
||||
<send_true_to>Change job status on success</send_true_to>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1536</xloc>
|
||||
<yloc>176</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Group by</name>
|
||||
<type>GroupBy</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<add_linenr>N</add_linenr>
|
||||
<all_rows>N</all_rows>
|
||||
<directory>${java.io.tmpdir}</directory>
|
||||
<fields>
|
||||
<field>
|
||||
<aggregate>has_appealing_violations_fz53_raw</aggregate>
|
||||
<subject>is_appealing_violations_fz53</subject>
|
||||
<type>MAX</type>
|
||||
</field>
|
||||
</fields>
|
||||
<give_back_row>N</give_back_row>
|
||||
<group>
|
||||
<field>
|
||||
<name>recruit_id</name>
|
||||
</field>
|
||||
</group>
|
||||
<ignore_aggregate>N</ignore_aggregate>
|
||||
<prefix>grp</prefix>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>80</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Identify last row in a stream</name>
|
||||
<type>DetectLastRow</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<resultfieldname>last_row</resultfieldname>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>880</xloc>
|
||||
<yloc>80</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Insert / update</name>
|
||||
<type>InsertUpdate</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>create_date</field>
|
||||
<name>create_date</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen_appealing_violations_fz53</table>
|
||||
<value>
|
||||
<name>recruit_id</name>
|
||||
<rename>recruit_id</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>create_date</name>
|
||||
<rename>create_date</rename>
|
||||
<update>N</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>number_appealed</name>
|
||||
<rename>number_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>date_appealed</name>
|
||||
<rename>date_appealed</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>case_number</name>
|
||||
<rename>case_number</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>decision_date</name>
|
||||
<rename>decision_date</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>result_appeal</name>
|
||||
<rename>result_appeal</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>name_commission</name>
|
||||
<rename>name_commission</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>grounds</name>
|
||||
<rename>grounds</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
<value>
|
||||
<name>hidden</name>
|
||||
<rename>hidden</rename>
|
||||
<update>Y</update>
|
||||
</value>
|
||||
</lookup>
|
||||
<update_bypassed>N</update_bypassed>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>688</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Table input</name>
|
||||
<type>TableInput</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<connection>postgres.decision-document-service</connection>
|
||||
<execute_each_row>N</execute_each_row>
|
||||
<sql>SELECT
|
||||
ad.recruit_id,
|
||||
ad.create_date, -- дата создания обжалования
|
||||
ad.appeal_number AS number_appealed, -- номер обжалуемого решения
|
||||
ad.appeal_date AS date_appealed, -- дата обжалуемого решения
|
||||
ad.result_number AS case_number, -- номер принятого решения
|
||||
ad.result_date AS decision_date, -- дата принятия решения
|
||||
CASE
|
||||
WHEN ad.result = '1' THEN 'Удовлетворена'
|
||||
WHEN ad.result = '2' THEN 'Частично удовлетворена'
|
||||
WHEN ad.result = '3' THEN 'Отказано в удовлетворении'
|
||||
ELSE NULL
|
||||
END AS result_appeal, -- код рассмотрения
|
||||
ad.commission_name AS name_commission, -- наименование комиссии, принявшей решение
|
||||
ad.reason_for_add_entry AS grounds, -- основание для внесения записи
|
||||
ad.hidden,
|
||||
CASE
|
||||
WHEN ad.hidden is false THEN 1
|
||||
ELSE 0
|
||||
END AS is_appealing_violations_fz53
|
||||
FROM public.appeal_document_dto ad
|
||||
JOIN public.recruit r ON r.id = ad.recruit_id AND '${IDM_ID}' != '' -- Проверка на пустую строку
|
||||
AND COALESCE(r.current_recruitment, r.target_recruitment) = '${IDM_ID}'
|
||||
AND '${M_R_CR_DATE}' >= ad.create_date
|
||||
--AND '${INFRINGEMENT_DATE}'::timestamp <= coalesce(ad.updated_at, ad.created_at) -- для дельты
|
||||
--WHERE hidden IS FALSE
|
||||
|
||||
${LIMIT_FW}</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>480</xloc>
|
||||
<yloc>208</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>Update</name>
|
||||
<type>Update</type>
|
||||
<description/>
|
||||
<distribute>N</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<commit>100</commit>
|
||||
<connection>ervu-dashboard</connection>
|
||||
<error_ignored>Y</error_ignored>
|
||||
<lookup>
|
||||
<key>
|
||||
<condition>=</condition>
|
||||
<field>recruit_id</field>
|
||||
<name>recruit_id</name>
|
||||
</key>
|
||||
<schema>ervu_dashboard</schema>
|
||||
<table>citizen</table>
|
||||
<value>
|
||||
<name>has_appealing_violations_fz53</name>
|
||||
<rename>has_appealing_violations_fz53</rename>
|
||||
</value>
|
||||
</lookup>
|
||||
<skip_lookup>N</skip_lookup>
|
||||
<use_batch>Y</use_batch>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1328</xloc>
|
||||
<yloc>80</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform>
|
||||
<name>User defined Java expression</name>
|
||||
<type>Janino</type>
|
||||
<description/>
|
||||
<distribute>Y</distribute>
|
||||
<custom_distribution/>
|
||||
<copies>1</copies>
|
||||
<partitioning>
|
||||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<formula>
|
||||
<field_name>has_appealing_violations_fz53</field_name>
|
||||
<formula_string>has_appealing_violations_fz53 == 1</formula_string>
|
||||
<value_type>Boolean</value_type>
|
||||
<value_length>-1</value_length>
|
||||
<value_precision>-1</value_precision>
|
||||
<replace_field/>
|
||||
</formula>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>1104</xloc>
|
||||
<yloc>80</yloc>
|
||||
</GUI>
|
||||
</transform>
|
||||
<transform_error_handling>
|
||||
<error>
|
||||
<source_transform>Insert / update</source_transform>
|
||||
<target_transform>Change job status on error</target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename/>
|
||||
<fields_valuename/>
|
||||
<codes_valuename/>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
<error>
|
||||
<source_transform>Update</source_transform>
|
||||
<target_transform>Change job status on error</target_transform>
|
||||
<is_enabled>Y</is_enabled>
|
||||
<nr_valuename/>
|
||||
<descriptions_valuename/>
|
||||
<fields_valuename/>
|
||||
<codes_valuename/>
|
||||
<max_errors/>
|
||||
<max_pct_errors/>
|
||||
<min_pct_rows/>
|
||||
</error>
|
||||
</transform_error_handling>
|
||||
<attributes/>
|
||||
</pipeline>
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue