feat: refs #7150
This commit is contained in:
parent
657150a9a7
commit
c30c0de92c
|
@ -8,12 +8,12 @@ BEGIN
|
|||
|
||||
DECLARE vDateStarted DATETIME;
|
||||
DECLARE vDateEnded DATETIME DEFAULT (util.VN_CURDATE() - INTERVAL 1 DAY);
|
||||
DECLARE vDaysSinceLastRecalculation INT;
|
||||
DECLARE vDaysAgoOffset INT;
|
||||
|
||||
SELECT daysSinceLastRecalculation INTO vDaysSinceLastRecalculation
|
||||
SELECT daysAgoOffset INTO vDaysAgoOffset
|
||||
FROM vn.greugeConfig;
|
||||
|
||||
SET vDateStarted = util.VN_CURDATE() - INTERVAL vDaysSinceLastRecalculation DAY;
|
||||
SET vDateStarted = util.VN_CURDATE() - INTERVAL vDaysAgoOffset DAY;
|
||||
|
||||
DROP TEMPORARY TABLE IF EXISTS tmp.dp;
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
ALTER TABLE IF EXISTS `vn`.`greugeConfig`
|
||||
ADD COLUMN IF NOT EXISTS `daysSinceLastRecalculation` int(11) NOT NULL;
|
||||
ADD COLUMN IF NOT EXISTS `daysAgoOffset` int(11) NOT NULL;
|
||||
|
||||
UPDATE vn.greugeConfig SET daysSinceLastRecalculation=15;
|
||||
UPDATE vn.greugeConfig SET daysAgoOffset=15;
|
Loading…
Reference in New Issue