52 lines
1.7 KiB
SQL
52 lines
1.7 KiB
SQL
--
|
|
-- $Id$
|
|
--
|
|
-- Customer specific once-script KFNS#83533-Default.SQL.
|
|
DEFINE thisfile = 'KFNS#83533-Default.sql'
|
|
DEFINE dbuser = '^KFNS'
|
|
|
|
SET ECHO ON
|
|
SET DEFINE ON
|
|
COLUMN fcltlogfile NEW_VALUE fcltlogfile NOPRINT;
|
|
COLUMN fcltcusterr NEW_VALUE fcltcusterr NOPRINT;
|
|
WHENEVER SQLERROR CONTINUE;
|
|
SELECT adm.getscriptspoolfile('&thisfile') AS fcltlogfile FROM DUAL;
|
|
SPOOL &fcltlogfile
|
|
WHENEVER SQLERROR EXIT;
|
|
SELECT adm.checkscriptcust('&dbuser') AS fcltcusterr FROM DUAL;
|
|
WHENEVER SQLERROR CONTINUE;
|
|
PROMPT &fcltcusterr
|
|
SET DEFINE OFF
|
|
|
|
------ payload begin ------
|
|
|
|
-- KFNS#83553: Met terugwerkende kracht toekennen Default-autorisatiegroep aan
|
|
-- via SAML-provisioning aangemaakte personen zonder login (die
|
|
-- deze autorisatiegroep niet meer automatisch krijgen toegekend)!
|
|
-- Inmiddels in de IDP doorgevoerd dat de Default-autorisatiegroep
|
|
-- wordt toegekend (*zonder underscore*).
|
|
INSERT INTO fac_gebruikersgroep (fac_groep_key, prs_perslid_key)
|
|
SELECT 1, p.prs_perslid_key -- 1=Default (*zonder underscore*)
|
|
FROM prs_perslid p
|
|
WHERE p.prs_perslid_verwijder IS NULL
|
|
AND p.prs_perslid_externid IS NOT NULL
|
|
AND p.prs_perslid_aanmaak > TO_DATE ('24-09-2024 18:00', 'dd-mm-yyyy hh24:mi')
|
|
AND NOT EXISTS
|
|
(SELECT 1
|
|
FROM fac_gebruikersgroep
|
|
WHERE fac_groep_key = 1
|
|
AND prs_perslid_key = p.prs_perslid_key)
|
|
ORDER BY p.prs_perslid_key;
|
|
|
|
------ payload end ------
|
|
|
|
SET DEFINE OFF
|
|
BEGIN adm.systrackscriptId ('$Id$', 1); END;
|
|
/
|
|
|
|
COMMIT;
|
|
SET ECHO OFF
|
|
SPOOL OFF
|
|
SET DEFINE ON
|
|
PROMPT Logfile of this upgrade is: &fcltlogfile
|