Skip to content

Commit

Permalink
Merge pull request #5620 from darshanasbg/feature-email-templates-rem…
Browse files Browse the repository at this point in the history
…ove-registry

Add sql scripts for notification template management
  • Loading branch information
darshanasbg authored Apr 15, 2024
2 parents 7917118 + 887a3c7 commit bf0a153
Show file tree
Hide file tree
Showing 8 changed files with 458 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1975,6 +1975,77 @@ CREATE TRIGGER BEFORE_SP_APP_DELETE
DELETE FROM AUTHORIZED_SCOPE WHERE APP_ID = OLD.UUID;
END
/
CREATE TABLE IDN_NOTIFICATION_TYPE (
ID INTEGER NOT NULL,
TYPE_KEY VARCHAR(255) NOT NULL,
NAME VARCHAR(255) NOT NULL,
CHANNEL VARCHAR(255) NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
CONSTRAINT NOTIFICATION_TYPE_KEY_CONSTRAINT UNIQUE (TYPE_KEY, CHANNEL, TENANT_ID),
CONSTRAINT NOTIFICATION_TYPE_NAME_CONSTRAINT UNIQUE (NAME, CHANNEL, TENANT_ID)
)
/
CREATE SEQUENCE IDN_NOTIFICATION_TYPE_SEQUENCE START WITH 1 INCREMENT BY 1 NOCACHE
/
CREATE TRIGGER IDN_NOTIFICATION_TYPE_TRIGGER NO CASCADE BEFORE INSERT ON IDN_NOTIFICATION_TYPE
REFERENCING NEW AS NEW FOR EACH ROW MODE DB2SQL
BEGIN ATOMIC
SET (NEW.ID)
= (NEXTVAL FOR IDN_NOTIFICATION_TYPE_SEQUENCE);
END
/
CREATE TABLE IDN_ORG_NOTIFICATION_TEMPLATE (
ID INTEGER NOT NULL,
TEMPLATE_KEY VARCHAR(50) NOT NULL,
LOCALE VARCHAR(50) NOT NULL,
SUBJECT VARCHAR(4000),
BODY CLOB,
FOOTER CLOB,
CONTENT_TYPE VARCHAR(50),
TYPE_ID INTEGER NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
FOREIGN KEY (TYPE_ID) REFERENCES IDN_NOTIFICATION_TYPE(ID) ON DELETE CASCADE,
CONSTRAINT ORG_NOTIFICATION_TEMPLATE_KEY_CONSTRAINT UNIQUE (TEMPLATE_KEY, TYPE_ID, TENANT_ID),
CONSTRAINT ORG_NOTIFICATION_TEMPLATE_LOCALE_CONSTRAINT UNIQUE (LOCALE, TYPE_ID, TENANT_ID)
)
/
CREATE SEQUENCE IDN_ORG_NOTIFICATION_TEMPLATE_SEQUENCE START WITH 1 INCREMENT BY 1 NOCACHE
/
CREATE TRIGGER IDN_ORG_NOTIFICATION_TEMPLATE_TRIGGER NO CASCADE BEFORE INSERT ON IDN_ORG_NOTIFICATION_TEMPLATE
REFERENCING NEW AS NEW FOR EACH ROW MODE DB2SQL
BEGIN ATOMIC
SET (NEW.ID)
= (NEXTVAL FOR IDN_ORG_NOTIFICATION_TEMPLATE_SEQUENCE);
END
/
CREATE TABLE IDN_APP_NOTIFICATION_TEMPLATE (
ID INTEGER NOT NULL,
TEMPLATE_KEY VARCHAR(50) NOT NULL,
LOCALE VARCHAR(50) NOT NULL,
SUBJECT VARCHAR(4000),
BODY CLOB,
FOOTER CLOB,
CONTENT_TYPE VARCHAR(50),
TYPE_ID INTEGER NOT NULL,
APP_ID VARCHAR(255) NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
FOREIGN KEY (TYPE_ID) REFERENCES IDN_NOTIFICATION_TYPE(ID) ON DELETE CASCADE,
CONSTRAINT APP_NOTIFICATION_TEMPLATE_KEY_CONSTRAINT UNIQUE (TEMPLATE_KEY, TYPE_ID, APP_ID, TENANT_ID),
CONSTRAINT APP_NOTIFICATION_TEMPLATE_LOCALE_CONSTRAINT UNIQUE (LOCALE, TYPE_ID, APP_ID, TENANT_ID)
)
/
CREATE SEQUENCE IDN_APP_NOTIFICATION_TEMPLATE_SEQUENCE START WITH 1 INCREMENT BY 1 NOCACHE
/
CREATE TRIGGER IDN_APP_NOTIFICATION_TEMPLATE_TRIGGER NO CASCADE BEFORE INSERT ON IDN_APP_NOTIFICATION_TEMPLATE
REFERENCING NEW AS NEW FOR EACH ROW MODE DB2SQL
BEGIN ATOMIC
SET (NEW.ID)
= (NEXTVAL FOR IDN_APP_NOTIFICATION_TEMPLATE_SEQUENCE);
END
/

-- --------------------------- INDEX CREATION -----------------------------
-- IDN_OAUTH2_ACCESS_TOKEN --
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1292,6 +1292,50 @@ CREATE TABLE IF NOT EXISTS AUTHORIZED_SCOPE(
CONSTRAINT AUTHORIZED_SCOPE_UNIQUE UNIQUE (APP_ID, SCOPE_ID)
);

CREATE TABLE IF NOT EXISTS IDN_NOTIFICATION_TYPE (
ID INTEGER NOT NULL AUTO_INCREMENT,
TYPE_KEY VARCHAR(255) NOT NULL,
NAME VARCHAR(255) NOT NULL,
CHANNEL VARCHAR(255) NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
CONSTRAINT NOTIFICATION_TYPE_KEY_CONSTRAINT UNIQUE (TYPE_KEY, CHANNEL, TENANT_ID),
CONSTRAINT NOTIFICATION_TYPE_NAME_CONSTRAINT UNIQUE (NAME, CHANNEL, TENANT_ID)
);

CREATE TABLE IF NOT EXISTS IDN_ORG_NOTIFICATION_TEMPLATE (
ID INTEGER NOT NULL AUTO_INCREMENT,
TEMPLATE_KEY VARCHAR(50) NOT NULL,
LOCALE VARCHAR(50) NOT NULL,
SUBJECT VARCHAR(4000),
BODY MEDIUMTEXT,
FOOTER MEDIUMTEXT,
CONTENT_TYPE VARCHAR(50),
TYPE_ID INTEGER NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
FOREIGN KEY (TYPE_ID) REFERENCES IDN_NOTIFICATION_TYPE(ID) ON DELETE CASCADE,
CONSTRAINT ORG_NOTIFICATION_TEMPLATE_KEY_CONSTRAINT UNIQUE (TEMPLATE_KEY, TYPE_ID, TENANT_ID),
CONSTRAINT ORG_NOTIFICATION_TEMPLATE_LOCALE_CONSTRAINT UNIQUE (LOCALE, TYPE_ID, TENANT_ID)
);

CREATE TABLE IF NOT EXISTS IDN_APP_NOTIFICATION_TEMPLATE (
ID INTEGER NOT NULL AUTO_INCREMENT,
TEMPLATE_KEY VARCHAR(50) NOT NULL,
LOCALE VARCHAR(50) NOT NULL,
SUBJECT VARCHAR(4000),
BODY MEDIUMTEXT,
FOOTER MEDIUMTEXT,
CONTENT_TYPE VARCHAR(50),
TYPE_ID INTEGER NOT NULL,
APP_ID VARCHAR(255) NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
FOREIGN KEY (TYPE_ID) REFERENCES IDN_NOTIFICATION_TYPE(ID) ON DELETE CASCADE,
CONSTRAINT APP_NOTIFICATION_TEMPLATE_KEY_CONSTRAINT UNIQUE (TEMPLATE_KEY, TYPE_ID, APP_ID, TENANT_ID),
CONSTRAINT APP_NOTIFICATION_TEMPLATE_LOCALE_CONSTRAINT UNIQUE (LOCALE, TYPE_ID, APP_ID, TENANT_ID)
);

-- --------------------------- INDEX CREATION -----------------------------
-- IDN_OAUTH2_ACCESS_TOKEN --
CREATE INDEX IDX_TC ON IDN_OAUTH2_ACCESS_TOKEN(TIME_CREATED);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1435,6 +1435,53 @@ CREATE TABLE AUTHORIZED_SCOPE (
CONSTRAINT AUTHORIZED_SCOPE_UNIQUE UNIQUE (APP_ID, SCOPE_ID)
);

IF NOT EXISTS (SELECT * FROM SYS.OBJECTS WHERE OBJECT_ID = OBJECT_ID(N'[DBO].[IDN_NOTIFICATION_TYPE]') AND TYPE IN (N'U'))
CREATE TABLE IDN_NOTIFICATION_TYPE (
ID INTEGER IDENTITY,
TYPE_KEY VARCHAR(255) NOT NULL,
NAME VARCHAR(255) NOT NULL,
CHANNEL VARCHAR(255) NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
CONSTRAINT NOTIFICATION_TYPE_KEY_CONSTRAINT UNIQUE (TYPE_KEY, CHANNEL, TENANT_ID),
CONSTRAINT NOTIFICATION_TYPE_NAME_CONSTRAINT UNIQUE (NAME, CHANNEL, TENANT_ID)
);

IF NOT EXISTS (SELECT * FROM SYS.OBJECTS WHERE OBJECT_ID = OBJECT_ID(N'[DBO].[IDN_ORG_NOTIFICATION_TEMPLATE]') AND TYPE IN (N'U'))
CREATE TABLE IDN_ORG_NOTIFICATION_TEMPLATE (
ID INTEGER IDENTITY,
TEMPLATE_KEY VARCHAR(50) NOT NULL,
LOCALE VARCHAR(50) NOT NULL,
SUBJECT VARCHAR(4000),
BODY TEXT,
FOOTER TEXT,
CONTENT_TYPE VARCHAR(50),
TYPE_ID INTEGER NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
FOREIGN KEY (TYPE_ID) REFERENCES IDN_NOTIFICATION_TYPE(ID) ON DELETE CASCADE,
CONSTRAINT ORG_NOTIFICATION_TEMPLATE_KEY_CONSTRAINT UNIQUE (TEMPLATE_KEY, TYPE_ID, TENANT_ID),
CONSTRAINT ORG_NOTIFICATION_TEMPLATE_LOCALE_CONSTRAINT UNIQUE (LOCALE, TYPE_ID, TENANT_ID)
);

IF NOT EXISTS (SELECT * FROM SYS.OBJECTS WHERE OBJECT_ID = OBJECT_ID(N'[DBO].[IDN_APP_NOTIFICATION_TEMPLATE]') AND TYPE IN (N'U'))
CREATE TABLE IDN_APP_NOTIFICATION_TEMPLATE (
ID INTEGER IDENTITY,
TEMPLATE_KEY VARCHAR(50) NOT NULL,
LOCALE VARCHAR(50) NOT NULL,
SUBJECT VARCHAR(4000),
BODY TEXT,
FOOTER TEXT,
CONTENT_TYPE VARCHAR(50),
TYPE_ID INTEGER NOT NULL,
APP_ID VARCHAR(255) NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
FOREIGN KEY (TYPE_ID) REFERENCES IDN_NOTIFICATION_TYPE(ID) ON DELETE CASCADE,
CONSTRAINT APP_NOTIFICATION_TEMPLATE_KEY_CONSTRAINT UNIQUE (TEMPLATE_KEY, TYPE_ID, APP_ID, TENANT_ID),
CONSTRAINT APP_NOTIFICATION_TEMPLATE_LOCALE_CONSTRAINT UNIQUE (LOCALE, TYPE_ID, APP_ID, TENANT_ID)
);

-- --------------------------- INDEX CREATION -----------------------------
-- IDN_OAUTH2_ACCESS_TOKEN --
CREATE INDEX IDX_TC ON IDN_OAUTH2_ACCESS_TOKEN(TIME_CREATED);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1452,6 +1452,50 @@ CREATE TABLE IF NOT EXISTS AUTHORIZED_SCOPE (
CONSTRAINT AUTHORIZED_SCOPE_UNIQUE UNIQUE (APP_ID, SCOPE_ID)
)ENGINE NDB;

CREATE TABLE IF NOT EXISTS IDN_NOTIFICATION_TYPE (
ID INTEGER NOT NULL AUTO_INCREMENT,
TYPE_KEY VARCHAR(255) NOT NULL,
NAME VARCHAR(255) NOT NULL,
CHANNEL VARCHAR(255) NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
CONSTRAINT NOTIFICATION_TYPE_KEY_CONSTRAINT UNIQUE (TYPE_KEY, CHANNEL, TENANT_ID),
CONSTRAINT NOTIFICATION_TYPE_NAME_CONSTRAINT UNIQUE (NAME, CHANNEL, TENANT_ID)
)ENGINE NDB;

CREATE TABLE IF NOT EXISTS IDN_ORG_NOTIFICATION_TEMPLATE (
ID INTEGER NOT NULL AUTO_INCREMENT,
TEMPLATE_KEY VARCHAR(50) NOT NULL,
LOCALE VARCHAR(50) NOT NULL,
SUBJECT VARCHAR(4000),
BODY MEDIUMTEXT,
FOOTER MEDIUMTEXT,
CONTENT_TYPE VARCHAR(50),
TYPE_ID INTEGER NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
FOREIGN KEY (TYPE_ID) REFERENCES IDN_NOTIFICATION_TYPE(ID) ON DELETE CASCADE,
CONSTRAINT ORG_NOTIFICATION_TEMPLATE_KEY_CONSTRAINT UNIQUE (TEMPLATE_KEY, TYPE_ID, TENANT_ID),
CONSTRAINT ORG_NOTIFICATION_TEMPLATE_LOCALE_CONSTRAINT UNIQUE (LOCALE, TYPE_ID, TENANT_ID)
)ENGINE NDB;

CREATE TABLE IF NOT EXISTS IDN_APP_NOTIFICATION_TEMPLATE (
ID INTEGER NOT NULL AUTO_INCREMENT,
TEMPLATE_KEY VARCHAR(50) NOT NULL,
LOCALE VARCHAR(50) NOT NULL,
SUBJECT VARCHAR(4000),
BODY MEDIUMTEXT,
FOOTER MEDIUMTEXT,
CONTENT_TYPE VARCHAR(50),
TYPE_ID INTEGER NOT NULL,
APP_ID VARCHAR(255) NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
FOREIGN KEY (TYPE_ID) REFERENCES IDN_NOTIFICATION_TYPE(ID) ON DELETE CASCADE,
CONSTRAINT APP_NOTIFICATION_TEMPLATE_KEY_CONSTRAINT UNIQUE (TEMPLATE_KEY, TYPE_ID, APP_ID, TENANT_ID),
CONSTRAINT APP_NOTIFICATION_TEMPLATE_LOCALE_CONSTRAINT UNIQUE (LOCALE, TYPE_ID, APP_ID, TENANT_ID)
)ENGINE NDB;

-- --------------------------- INDEX CREATION -----------------------------
-- IDN_OAUTH2_ACCESS_TOKEN --
CREATE INDEX IDX_TC
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1322,6 +1322,50 @@ CREATE TABLE IF NOT EXISTS ROLE_SCOPE (
FOREIGN KEY (SCOPE_ID) REFERENCES SCOPE(ID) ON DELETE CASCADE
)DEFAULT CHARACTER SET latin1 ENGINE INNODB;

CREATE TABLE IF NOT EXISTS IDN_NOTIFICATION_TYPE (
ID INTEGER NOT NULL AUTO_INCREMENT,
TYPE_KEY VARCHAR(255) NOT NULL,
NAME VARCHAR(255) NOT NULL,
CHANNEL VARCHAR(255) NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
CONSTRAINT NOTIFICATION_TYPE_KEY_CONSTRAINT UNIQUE (TYPE_KEY, CHANNEL, TENANT_ID),
CONSTRAINT NOTIFICATION_TYPE_NAME_CONSTRAINT UNIQUE (NAME, CHANNEL, TENANT_ID)
)DEFAULT CHARACTER SET latin1 ENGINE INNODB;

CREATE TABLE IF NOT EXISTS IDN_ORG_NOTIFICATION_TEMPLATE (
ID INTEGER NOT NULL AUTO_INCREMENT,
TEMPLATE_KEY VARCHAR(50) NOT NULL,
LOCALE VARCHAR(50) NOT NULL,
SUBJECT VARCHAR(4000),
BODY MEDIUMTEXT,
FOOTER MEDIUMTEXT,
CONTENT_TYPE VARCHAR(50),
TYPE_ID INTEGER NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
FOREIGN KEY (TYPE_ID) REFERENCES IDN_NOTIFICATION_TYPE(ID) ON DELETE CASCADE,
CONSTRAINT ORG_NOTIFICATION_TEMPLATE_KEY_CONSTRAINT UNIQUE (TEMPLATE_KEY, TYPE_ID, TENANT_ID),
CONSTRAINT ORG_NOTIFICATION_TEMPLATE_LOCALE_CONSTRAINT UNIQUE (LOCALE, TYPE_ID, TENANT_ID)
)DEFAULT CHARACTER SET latin1 ENGINE INNODB;

CREATE TABLE IF NOT EXISTS IDN_APP_NOTIFICATION_TEMPLATE (
ID INTEGER NOT NULL AUTO_INCREMENT,
TEMPLATE_KEY VARCHAR(50) NOT NULL,
LOCALE VARCHAR(50) NOT NULL,
SUBJECT VARCHAR(4000),
BODY MEDIUMTEXT,
FOOTER MEDIUMTEXT,
CONTENT_TYPE VARCHAR(50),
TYPE_ID INTEGER NOT NULL,
APP_ID VARCHAR(255) NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
FOREIGN KEY (TYPE_ID) REFERENCES IDN_NOTIFICATION_TYPE(ID) ON DELETE CASCADE,
CONSTRAINT APP_NOTIFICATION_TEMPLATE_KEY_CONSTRAINT UNIQUE (TEMPLATE_KEY, TYPE_ID, APP_ID, TENANT_ID),
CONSTRAINT APP_NOTIFICATION_TEMPLATE_LOCALE_CONSTRAINT UNIQUE (LOCALE, TYPE_ID, APP_ID, TENANT_ID)
)DEFAULT CHARACTER SET latin1 ENGINE INNODB;

-- --------------------------- INDEX CREATION -----------------------------
-- IDN_OAUTH2_ACCESS_TOKEN --
CREATE INDEX IDX_TC ON IDN_OAUTH2_ACCESS_TOKEN(TIME_CREATED);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2030,6 +2030,84 @@ CREATE OR REPLACE TRIGGER IDN_ORG_USER_INVITE_ASSIGNMENT_TRIG
SELECT IDN_ORG_USER_INVITE_ASSIGNMENT_SEQ.nextval INTO :NEW.ID FROM dual;
END;
/
CREATE TABLE IDN_NOTIFICATION_TYPE (
ID INTEGER NOT NULL,
TYPE_KEY VARCHAR(255) NOT NULL,
NAME VARCHAR(255) NOT NULL,
CHANNEL VARCHAR(255) NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
CONSTRAINT NOTIFICATION_TYPE_KEY_CONSTRAINT UNIQUE (TYPE_KEY, CHANNEL, TENANT_ID),
CONSTRAINT NOTIFICATION_TYPE_NAME_CONSTRAINT UNIQUE (NAME, CHANNEL, TENANT_ID)
)
/
CREATE SEQUENCE IDN_NOTIFICATION_TYPE_SEQ START WITH 1 INCREMENT BY 1 NOCACHE
/
CREATE OR REPLACE TRIGGER IDN_NOTIFICATION_TYPE_TRIG
BEFORE INSERT
ON IDN_NOTIFICATION_TYPE
REFERENCING NEW AS NEW
FOR EACH ROW
BEGIN
SELECT IDN_NOTIFICATION_TYPE_SEQ.nextval INTO :NEW.ID FROM dual;
END;
/
CREATE TABLE IDN_ORG_NOTIFICATION_TEMPLATE (
ID INTEGER NOT NULL,
TEMPLATE_KEY VARCHAR(50) NOT NULL,
LOCALE VARCHAR(50) NOT NULL,
SUBJECT VARCHAR(4000),
BODY CLOB,
FOOTER CLOB,
CONTENT_TYPE VARCHAR(50),
TYPE_ID INTEGER NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
FOREIGN KEY (TYPE_ID) REFERENCES IDN_NOTIFICATION_TYPE(ID) ON DELETE CASCADE,
CONSTRAINT ORG_NOTIFICATION_TEMPLATE_KEY_CONSTRAINT UNIQUE (TEMPLATE_KEY, TYPE_ID, TENANT_ID),
CONSTRAINT ORG_NOTIFICATION_TEMPLATE_LOCALE_CONSTRAINT UNIQUE (LOCALE, TYPE_ID, TENANT_ID)
)
/
CREATE SEQUENCE IDN_ORG_NOTIFICATION_TEMPLATE_SEQ START WITH 1 INCREMENT BY 1 NOCACHE
/
CREATE OR REPLACE TRIGGER IDN_ORG_NOTIFICATION_TEMPLATE_TRIG
BEFORE INSERT
ON IDN_ORG_NOTIFICATION_TEMPLATE
REFERENCING NEW AS NEW
FOR EACH ROW
BEGIN
SELECT IDN_ORG_NOTIFICATION_TEMPLATE_SEQ.nextval INTO :NEW.ID FROM dual;
END;
/
CREATE TABLE IDN_APP_NOTIFICATION_TEMPLATE (
ID INTEGER NOT NULL,
TEMPLATE_KEY VARCHAR(50) NOT NULL,
LOCALE VARCHAR(50) NOT NULL,
SUBJECT VARCHAR(4000),
BODY CLOB,
FOOTER CLOB,
CONTENT_TYPE VARCHAR(50),
TYPE_ID INTEGER NOT NULL,
APP_ID VARCHAR(255) NOT NULL,
TENANT_ID INTEGER NOT NULL,
PRIMARY KEY (ID),
FOREIGN KEY (TYPE_ID) REFERENCES IDN_NOTIFICATION_TYPE(ID) ON DELETE CASCADE,
CONSTRAINT APP_NOTIFICATION_TEMPLATE_KEY_CONSTRAINT UNIQUE (TEMPLATE_KEY, TYPE_ID, APP_ID, TENANT_ID),
CONSTRAINT APP_NOTIFICATION_TEMPLATE_LOCALE_CONSTRAINT UNIQUE (LOCALE, TYPE_ID, APP_ID, TENANT_ID)
)
/
CREATE SEQUENCE IDN_APP_NOTIFICATION_TEMPLATE_SEQ START WITH 1 INCREMENT BY 1 NOCACHE
/
CREATE OR REPLACE TRIGGER IDN_APP_NOTIFICATION_TEMPLATE_TRIG
BEFORE INSERT
ON IDN_APP_NOTIFICATION_TEMPLATE
REFERENCING NEW AS NEW
FOR EACH ROW
BEGIN
SELECT IDN_APP_NOTIFICATION_TEMPLATE_SEQ.nextval INTO :NEW.ID FROM dual;
END;
/

-- --------------------------- INDEX CREATION -----------------------------
-- IDN_OAUTH2_ACCESS_TOKEN --
CREATE INDEX IDX_TC ON IDN_OAUTH2_ACCESS_TOKEN(TIME_CREATED)
Expand Down
Loading

0 comments on commit bf0a153

Please sign in to comment.