liquid_feedback_core

diff update/core-update.v3.1.0-v3.2.0.sql @ 515:ab05fb3bf974

Set column "notification_hour" of "member" table by default to random number
author jbe
date Sun Apr 17 17:36:41 2016 +0200 (2016-04-17)
parents 705097d1b1f3
children
line diff
     1.1 --- a/update/core-update.v3.1.0-v3.2.0.sql	Sun Apr 17 15:14:14 2016 +0200
     1.2 +++ b/update/core-update.v3.1.0-v3.2.0.sql	Sun Apr 17 17:36:41 2016 +0200
     1.3 @@ -8,7 +8,7 @@
     1.4  ALTER TABLE "member" ADD COLUMN "notification_counter"     INT4    NOT NULL DEFAULT 1;
     1.5  ALTER TABLE "member" ADD COLUMN "notification_sample_size" INT4    NOT NULL DEFAULT 3;
     1.6  ALTER TABLE "member" ADD COLUMN "notification_dow"         INT4    CHECK ("notification_dow" BETWEEN 0 AND 6);
     1.7 -ALTER TABLE "member" ADD COLUMN "notification_hour"        INT4    CHECK ("notification_hour" BETWEEN 0 AND 23);
     1.8 +ALTER TABLE "member" ADD COLUMN "notification_hour"        INT4    DEFAULT floor(random() * 24) CHECK ("notification_hour" BETWEEN 0 AND 23);
     1.9  ALTER TABLE "member" ADD COLUMN "notification_sent"        TIMESTAMP;
    1.10  ALTER TABLE "member" ADD
    1.11    CONSTRAINT "notification_dow_requires_notification_hour"

Impressum / About Us