Files
Customer/onces/BLCC/BLCC#37691.sql
Maarten van der Heide 31b4475f03 BLCC#37691 Facturatieproces M2/Maandtarief blijkt jaartarief en andere fixes
svn path=/Customer/; revision=35413
2017-09-22 13:05:54 +00:00

39 lines
941 B
SQL

--
-- $Id$
--
-- Customer specific once-script BLCC#37691.SQL.
DEFINE thisfile = 'BLCC#37691.SQL'
DEFINE dbuser = '^BLCC'
SET ECHO ON
SET DEFINE ON
COLUMN fcltlogfile NEW_VALUE fcltlogfile NOPRINT;
WHENEVER SQLERROR EXIT;
SELECT adm.scriptspoolfile('&dbuser', '&thisfile') AS fcltlogfile FROM DUAL;
WHENEVER SQLERROR CONTINUE;
SPOOL &fcltlogfile
SET DEFINE OFF
------ payload begin ------
UPDATE cnt_contract
SET cnt_contract_korting = ROUND (cnt_contract_korting / 12, 2)
WHERE cnt_contract_verwijder IS NULL
AND ins_discipline_key = 621
AND cnt_contract_status = 0
AND cnt_contract_looptijd_tot > ADD_MONTHS (TRUNC (SYSDATE, 'mm'), 2)
AND cnt_contract_korting IS NOT NULL;
------ 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