--
-- $Id$
--
-- Aanpassen omschrijving factuurregels ivm foutieve huurcorrectie op additional costs
-- nybu#62585: Campus | huurlijst klopt niet
--
DEFINE thisfile = 'nybu#62585'
DEFINE dbuser   = '^NYBU'

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 ------

UPDATE nybu_huur_archief
   SET omschrijving = REPLACE (ha.omschrijving, 'add. costs', ' add_costs')
 WHERE     cnt_contract_key IN (21896, 21922, 21921)
       AND periode = '202005'
       AND omschrijving LIKE 'Credit add. costs%';
       
COMMIT;

------ 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
