some fixes
This commit is contained in:
parent
bc048a54ac
commit
7e21c2b7cb
5 changed files with 22 additions and 16 deletions
|
|
@ -307,20 +307,23 @@ VALUES (DEFAULT, '${JOB_NAME}', 'PROCESSING', DEFAULT, null, '${IDM_ID}');
|
|||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compress>N</compress>
|
||||
<directory>${java.io.tmpdir}</directory>
|
||||
<prefix/>
|
||||
<sort_size>1000000</sort_size>
|
||||
<free_memory/>
|
||||
<compress>N</compress>
|
||||
<compress_variable/>
|
||||
<unique_rows>Y</unique_rows>
|
||||
<fields>
|
||||
<field>
|
||||
<name>recruit_id</name>
|
||||
<ascending>Y</ascending>
|
||||
<case_sensitive>N</case_sensitive>
|
||||
<collator_enabled>N</collator_enabled>
|
||||
<collator_strength>0</collator_strength>
|
||||
<name>recruit_id</name>
|
||||
<presorted>N</presorted>
|
||||
</field>
|
||||
</fields>
|
||||
<sort_size>1000000</sort_size>
|
||||
<unique_rows>Y</unique_rows>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>704</xloc>
|
||||
|
|
@ -392,7 +395,7 @@ SELECT fd.recruit_id,
|
|||
to_date(nedeesposob_elem ->> 'dataOkonch', 'YYYY-MM-DD') AS deregistration_date,
|
||||
true as has_incapacity_info
|
||||
FROM filteredData fd
|
||||
CROSS JOIN LATERAL jsonb_array_elements(fd.nedeesposob_arr -> 'svedFL' -> 'svedNedeesp' -> 'nedeesposob') AS nedeesposob_elem;</sql>
|
||||
CROSS JOIN LATERAL jsonb_array_elements(fd.nedeesposob_arr) AS nedeesposob_elem;</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
|
|
|
|||
|
|
@ -310,20 +310,23 @@ and recruitment_id = '${IDM_ID}';</sql>
|
|||
<method>none</method>
|
||||
<schema_name/>
|
||||
</partitioning>
|
||||
<compress>N</compress>
|
||||
<directory>${java.io.tmpdir}</directory>
|
||||
<prefix/>
|
||||
<sort_size>1000000</sort_size>
|
||||
<free_memory/>
|
||||
<compress>N</compress>
|
||||
<compress_variable/>
|
||||
<unique_rows>Y</unique_rows>
|
||||
<fields>
|
||||
<field>
|
||||
<name>recruit_id</name>
|
||||
<ascending>Y</ascending>
|
||||
<case_sensitive>N</case_sensitive>
|
||||
<collator_enabled>N</collator_enabled>
|
||||
<collator_strength>0</collator_strength>
|
||||
<name>recruit_id</name>
|
||||
<presorted>N</presorted>
|
||||
</field>
|
||||
</fields>
|
||||
<sort_size>1000000</sort_size>
|
||||
<unique_rows>Y</unique_rows>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
<xloc>832</xloc>
|
||||
|
|
@ -394,7 +397,7 @@ SELECT fd.recruit_id,
|
|||
to_date(nedeesposob_elem ->> 'dataPrisv', 'YYYY-MM-DD') AS register_date,
|
||||
to_date(nedeesposob_elem ->> 'dataOkonch', 'YYYY-MM-DD') AS deregistration_date
|
||||
FROM filteredData fd
|
||||
CROSS JOIN LATERAL jsonb_array_elements(fd.nedeesposob_arr -> 'svedFL' -> 'svedNedeesp' -> 'nedeesposob') AS nedeesposob_elem;</sql>
|
||||
CROSS JOIN LATERAL jsonb_array_elements(fd.nedeesposob_arr) AS nedeesposob_elem;</sql>
|
||||
<variables_active>Y</variables_active>
|
||||
<attributes/>
|
||||
<GUI>
|
||||
|
|
|
|||
|
|
@ -385,7 +385,7 @@ VALUES (DEFAULT, '${JOB_NAME}', 'PROCESSING', DEFAULT, null, '${IDM_ID}');
|
|||
ri.info -> 'svedFL' -> 'svedNPD' -> 'npd' -> 'aktNPD' as npd_elem,
|
||||
true as actual
|
||||
from ervu_dashboard.recruits_info ri
|
||||
where ri.info -> 'svedFL' -> 'svedNPD' ->> 'aktNPD' != 'null'
|
||||
where ri.info -> 'svedFL' -> 'svedNPD' -> 'npd' ->> 'aktNPD' != 'null'
|
||||
AND (ri.current_recruitment_id = '${IDM_ID}' or (ri.current_recruitment_id is null and ri.target_recruitment_id = '${IDM_ID}'))
|
||||
|
||||
union all
|
||||
|
|
@ -394,7 +394,7 @@ VALUES (DEFAULT, '${JOB_NAME}', 'PROCESSING', DEFAULT, null, '${IDM_ID}');
|
|||
ri.info -> 'svedFL' -> 'svedNPD' -> 'npd' -> 'predNPD' as npd_elem,
|
||||
false as actual
|
||||
from ervu_dashboard.recruits_info ri
|
||||
where ri.info -> 'svedFL' -> 'svedNPD' ->> 'predNPD' != 'null'
|
||||
where ri.info -> 'svedFL' -> 'svedNPD' -> 'npd' ->> 'predNPD' != 'null'
|
||||
AND (ri.current_recruitment_id = '${IDM_ID}' or (ri.current_recruitment_id is null and ri.target_recruitment_id = '${IDM_ID}'))
|
||||
)
|
||||
select fd.recruit_id,
|
||||
|
|
|
|||
|
|
@ -528,8 +528,8 @@ and recruitment_id = '${IDM_ID}';</sql>
|
|||
ri.info -> 'svedFL' -> 'svedNPD' -> 'npd' -> 'aktNPD' as akt_npd_elem,
|
||||
ri.info -> 'svedFL' -> 'svedNPD' -> 'npd' -> 'predNPD' as pred_npd_elem
|
||||
from ervu_dashboard.recruits_info ri
|
||||
where ri.info -> 'svedFL' -> 'svedNPD' ->> 'aktNPD' != 'null'
|
||||
and (to_date(ri.info -> 'svedFL' -> 'svedNPD' -> 'npd' -> 'aktNPD' ->> 'dataSved', 'YYYY-MM-DD') > '${MAX_SOURCE_UPDATE_DATE}'
|
||||
where ri.info -> 'svedFL' -> 'svedNPD' ->> 'npd' != 'null'
|
||||
and (to_date(ri.info -> 'svedFL' -> 'svedNPD' -> 'npd' -> 'aktNPD' ->> 'dataSved', 'YYYY-MM-DD') > '${MAX_SOURCE_UPDATE_DATE}'
|
||||
or to_date(ri.info -> 'svedFL' -> 'svedNPD' -> 'npd' -> 'predNPD' ->> 'dataSved', 'YYYY-MM-DD') > '${MAX_SOURCE_UPDATE_DATE}')
|
||||
AND (ri.current_recruitment_id = '${IDM_ID}' or (ri.current_recruitment_id is null and ri.target_recruitment_id = '${IDM_ID}'))
|
||||
)
|
||||
|
|
|
|||
|
|
@ -386,7 +386,7 @@ SET status = 'PROCESSING',
|
|||
ri.info -> 'svedFL' -> 'svedNPD' -> 'npd' -> 'aktNPD' as npd_elem,
|
||||
true as actual
|
||||
from ervu_dashboard.recruits_info ri
|
||||
where ri.info -> 'svedFL' -> 'svedNPD' ->> 'aktNPD' != 'null'
|
||||
where ri.info -> 'svedFL' -> 'svedNPD' -> 'npd' ->> 'aktNPD' != 'null'
|
||||
AND (ri.current_recruitment_id = '${IDM_ID}' or (ri.current_recruitment_id is null and ri.target_recruitment_id = '${IDM_ID}'))
|
||||
|
||||
union all
|
||||
|
|
@ -395,7 +395,7 @@ SET status = 'PROCESSING',
|
|||
ri.info -> 'svedFL' -> 'svedNPD' -> 'npd' -> 'predNPD' as npd_elem,
|
||||
false as actual
|
||||
from ervu_dashboard.recruits_info ri
|
||||
where ri.info -> 'svedFL' -> 'svedNPD' ->> 'predNPD' != 'null'
|
||||
where ri.info -> 'svedFL' -> 'svedNPD' -> 'npd' ->> 'predNPD' != 'null'
|
||||
AND (ri.current_recruitment_id = '${IDM_ID}' or (ri.current_recruitment_id is null and ri.target_recruitment_id = '${IDM_ID}'))
|
||||
)
|
||||
select fd.recruit_id,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue