blob: 2833cbd7b8f7d1b57edacc1900e75c62498f0e17 [file] [log] [blame]
jimmydot3982f4f2017-05-07 14:58:24 -04001/*-
2 * ============LICENSE_START=======================================================
3 * VID
4 * ================================================================================
5 * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
6 * ================================================================================
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
10 *
11 * http://www.apache.org/licenses/LICENSE-2.0
12 *
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
18 * ============LICENSE_END=========================================================
19 */
20-- ----------------------------------------------------------------------------
21-- MySQL Workbench Migration
22-- Migrated Schemata: vid_openecomp_epsdk
23-- Source Schemata: ecomp_sd
24-- Created: Sun Nov 13 08:58:53 2016
25-- Workbench Version: 6.3.6
26-- ----------------------------------------------------------------------------
27
28SET FOREIGN_KEY_CHECKS = 0;
29
30-- ----------------------------------------------------------------------------
31-- Schema vid_openecomp_epsdk
32-- ----------------------------------------------------------------------------
33CREATE SCHEMA IF NOT EXISTS `vid_openecomp_epsdk` ;
34
35USE vid_openecomp_epsdk;
Sonsino, Ofir (os0695)e54db1f2018-10-21 14:29:55 +030036
37
38CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`schema_info` (
39 `SCHEMA_ID` VARCHAR(25) NOT NULL,
40 `SCHEMA_DESC` VARCHAR(75) NOT NULL,
41 `DATASOURCE_TYPE` VARCHAR(100) NULL DEFAULT NULL,
42 `CONNECTION_URL` VARCHAR(200) NOT NULL,
43 `USER_NAME` VARCHAR(45) NOT NULL,
44 `PASSWORD` VARCHAR(45) NULL DEFAULT NULL,
45 `DRIVER_CLASS` VARCHAR(100) NOT NULL,
46 `MIN_POOL_SIZE` INT(11) NOT NULL,
47 `MAX_POOL_SIZE` INT(11) NOT NULL,
48 `IDLE_CONNECTION_TEST_PERIOD` INT(11) NOT NULL)
49ENGINE = InnoDB
50DEFAULT CHARACTER SET = utf8;
51
jimmydot3982f4f2017-05-07 14:58:24 -040052-- ----------------------------------------------------------------------------
53-- Table vid_openecomp_epsdk.cr_favorite_reports
54-- ----------------------------------------------------------------------------
55CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_favorite_reports` (
56 `USER_ID` INT(11) NOT NULL,
57 `REP_ID` INT(11) NOT NULL,
58 PRIMARY KEY (`USER_ID`, `REP_ID`))
59ENGINE = InnoDB
60DEFAULT CHARACTER SET = utf8;
61
62-- ----------------------------------------------------------------------------
63-- Table vid_openecomp_epsdk.cr_filehist_log
64-- ----------------------------------------------------------------------------
65CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_filehist_log` (
66 `SCHEDULE_ID` DECIMAL(11,0) NOT NULL,
67 `URL` VARCHAR(4000) NULL DEFAULT NULL,
68 `NOTES` VARCHAR(3500) NULL DEFAULT NULL,
69 `RUN_TIME` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP)
70ENGINE = InnoDB
71DEFAULT CHARACTER SET = utf8;
72
73-- ----------------------------------------------------------------------------
74-- Table vid_openecomp_epsdk.cr_folder
75-- ----------------------------------------------------------------------------
76CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_folder` (
77 `FOLDER_ID` INT(11) NOT NULL,
78 `FOLDER_NAME` VARCHAR(50) NOT NULL,
79 `DESCR` VARCHAR(500) NULL DEFAULT NULL,
80 `CREATE_ID` INT(11) NOT NULL,
81 `CREATE_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
82 `PARENT_FOLDER_ID` INT(11) NULL DEFAULT NULL,
83 `PUBLIC_YN` VARCHAR(1) NOT NULL DEFAULT 'N',
84 PRIMARY KEY (`FOLDER_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +020085 INDEX `FK_PARENT_KEY_CR_FOLDER` (`PARENT_FOLDER_ID` ASC),
86 CONSTRAINT `FK_PARENT_KEY_CR_FOLDER`
jimmydot3982f4f2017-05-07 14:58:24 -040087 FOREIGN KEY (`PARENT_FOLDER_ID`)
88 REFERENCES `vid_openecomp_epsdk`.`cr_folder` (`FOLDER_ID`))
89ENGINE = InnoDB
90DEFAULT CHARACTER SET = utf8;
91
92-- ----------------------------------------------------------------------------
93-- Table vid_openecomp_epsdk.cr_folder_access
94-- ----------------------------------------------------------------------------
95CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_folder_access` (
96 `FOLDER_ACCESS_ID` DECIMAL(11,0) NOT NULL,
97 `FOLDER_ID` DECIMAL(11,0) NOT NULL,
98 `ORDER_NO` DECIMAL(11,0) NOT NULL,
99 `ROLE_ID` DECIMAL(11,0) NULL DEFAULT NULL,
100 `USER_ID` DECIMAL(11,0) NULL DEFAULT NULL,
101 `READ_ONLY_YN` VARCHAR(1) NOT NULL DEFAULT 'N',
102 PRIMARY KEY (`FOLDER_ACCESS_ID`))
103ENGINE = InnoDB
104DEFAULT CHARACTER SET = utf8;
105
106-- ----------------------------------------------------------------------------
107-- Table vid_openecomp_epsdk.cr_hist_user_map
108-- ----------------------------------------------------------------------------
109CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_hist_user_map` (
110 `HIST_ID` INT(11) NOT NULL,
111 `USER_ID` INT(11) NOT NULL,
112 PRIMARY KEY (`HIST_ID`, `USER_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200113 INDEX `SYS_C0014617` (`USER_ID` ASC),
114 CONSTRAINT `SYS_C0014616`
jimmydot3982f4f2017-05-07 14:58:24 -0400115 FOREIGN KEY (`HIST_ID`)
116 REFERENCES `vid_openecomp_epsdk`.`cr_report_file_history` (`HIST_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200117 CONSTRAINT `SYS_C0014617`
jimmydot3982f4f2017-05-07 14:58:24 -0400118 FOREIGN KEY (`USER_ID`)
119 REFERENCES `vid_openecomp_epsdk`.`fn_user` (`USER_ID`))
120ENGINE = InnoDB
121DEFAULT CHARACTER SET = utf8;
122
123-- ----------------------------------------------------------------------------
124-- Table vid_openecomp_epsdk.cr_lu_file_type
125-- ----------------------------------------------------------------------------
126CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_lu_file_type` (
127 `LOOKUP_ID` DECIMAL(2,0) NOT NULL,
128 `LOOKUP_DESCR` VARCHAR(255) NOT NULL,
129 `ACTIVE_YN` CHAR(1) NULL DEFAULT 'Y',
130 `ERROR_CODE` DECIMAL(11,0) NULL DEFAULT NULL,
131 PRIMARY KEY (`LOOKUP_ID`))
132ENGINE = InnoDB
133DEFAULT CHARACTER SET = utf8;
134
135-- ----------------------------------------------------------------------------
136-- Table vid_openecomp_epsdk.cr_raptor_action_img
137-- ----------------------------------------------------------------------------
138CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_raptor_action_img` (
139 `IMAGE_ID` VARCHAR(100) NOT NULL,
140 `IMAGE_LOC` VARCHAR(400) NULL DEFAULT NULL,
141 PRIMARY KEY (`IMAGE_ID`))
142ENGINE = InnoDB
143DEFAULT CHARACTER SET = utf8;
144
145-- ----------------------------------------------------------------------------
146-- Table vid_openecomp_epsdk.cr_raptor_pdf_img
147-- ----------------------------------------------------------------------------
148CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_raptor_pdf_img` (
149 `IMAGE_ID` VARCHAR(100) NOT NULL,
150 `IMAGE_LOC` VARCHAR(400) NULL DEFAULT NULL,
151 PRIMARY KEY (`IMAGE_ID`))
152ENGINE = InnoDB
153DEFAULT CHARACTER SET = utf8;
154
155-- ----------------------------------------------------------------------------
156-- Table vid_openecomp_epsdk.cr_remote_schema_info
157-- ----------------------------------------------------------------------------
158CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_remote_schema_info` (
159 `SCHEMA_PREFIX` VARCHAR(5) NOT NULL,
160 `SCHEMA_DESC` VARCHAR(75) NOT NULL,
161 `DATASOURCE_TYPE` VARCHAR(100) NULL DEFAULT NULL,
162 PRIMARY KEY (`SCHEMA_PREFIX`))
163ENGINE = InnoDB
164DEFAULT CHARACTER SET = utf8;
165
166-- ----------------------------------------------------------------------------
167-- Table vid_openecomp_epsdk.cr_report
168-- ----------------------------------------------------------------------------
169CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_report` (
170 `REP_ID` DECIMAL(11,0) NOT NULL,
171 `TITLE` VARCHAR(100) NOT NULL,
172 `DESCR` VARCHAR(255) NULL DEFAULT NULL,
173 `PUBLIC_YN` VARCHAR(1) NOT NULL DEFAULT 'N',
174 `REPORT_XML` TEXT NULL DEFAULT NULL,
175 `CREATE_ID` DECIMAL(11,0) NULL DEFAULT NULL,
176 `CREATE_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
177 `MAINT_ID` DECIMAL(11,0) NULL DEFAULT NULL,
178 `MAINT_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
179 `MENU_ID` VARCHAR(500) NULL DEFAULT NULL,
180 `MENU_APPROVED_YN` VARCHAR(1) NOT NULL DEFAULT 'N',
181 `OWNER_ID` DECIMAL(11,0) NULL DEFAULT NULL,
182 `FOLDER_ID` INT(11) NULL DEFAULT '0',
183 `DASHBOARD_TYPE_YN` VARCHAR(1) NULL DEFAULT 'N',
184 `DASHBOARD_YN` VARCHAR(1) NULL DEFAULT 'N',
185 PRIMARY KEY (`REP_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200186 INDEX `CR_REPORT_CREATE_IDPUBLIC_YNTITLE` (`CREATE_ID` ASC, `PUBLIC_YN` ASC, `TITLE` ASC))
jimmydot3982f4f2017-05-07 14:58:24 -0400187ENGINE = InnoDB
188DEFAULT CHARACTER SET = utf8;
189
190-- ----------------------------------------------------------------------------
191-- Table vid_openecomp_epsdk.cr_report_access
192-- ----------------------------------------------------------------------------
193CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_report_access` (
194 `REP_ID` DECIMAL(11,0) NOT NULL,
195 `ORDER_NO` DECIMAL(11,0) NOT NULL,
196 `ROLE_ID` DECIMAL(11,0) NULL DEFAULT NULL,
197 `USER_ID` DECIMAL(11,0) NULL DEFAULT NULL,
198 `READ_ONLY_YN` VARCHAR(1) NOT NULL DEFAULT 'N',
199 PRIMARY KEY (`REP_ID`, `ORDER_NO`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200200 CONSTRAINT `FK_CR_REPOR_REF_8550_CR_REPOR`
jimmydot3982f4f2017-05-07 14:58:24 -0400201 FOREIGN KEY (`REP_ID`)
202 REFERENCES `vid_openecomp_epsdk`.`cr_report` (`REP_ID`))
203ENGINE = InnoDB
204DEFAULT CHARACTER SET = utf8;
205
206-- ----------------------------------------------------------------------------
207-- Table vid_openecomp_epsdk.cr_report_dwnld_log
208-- ----------------------------------------------------------------------------
209CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_report_dwnld_log` (
210 `USER_ID` DECIMAL(11,0) NOT NULL,
211 `REP_ID` INT(11) NOT NULL,
212 `FILE_NAME` VARCHAR(100) NOT NULL,
213 `DWNLD_START_TIME` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
214 `RECORD_READY_TIME` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
215 `FILTER_PARAMS` VARCHAR(2000) NULL DEFAULT NULL)
216ENGINE = InnoDB
217DEFAULT CHARACTER SET = utf8;
218
219-- ----------------------------------------------------------------------------
220-- Table vid_openecomp_epsdk.cr_report_email_sent_log
221-- ----------------------------------------------------------------------------
222CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_report_email_sent_log` (
223 `LOG_ID` INT(11) NOT NULL,
224 `SCHEDULE_ID` DECIMAL(11,0) NULL DEFAULT NULL,
225 `GEN_KEY` VARCHAR(25) NOT NULL,
226 `REP_ID` DECIMAL(11,0) NOT NULL,
227 `USER_ID` DECIMAL(11,0) NULL DEFAULT NULL,
228 `SENT_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
229 `ACCESS_FLAG` VARCHAR(1) NOT NULL DEFAULT 'Y',
230 `TOUCH_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
231 PRIMARY KEY (`LOG_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200232 INDEX `FK_CR_REPORT_REP_ID` (`REP_ID` ASC),
233 CONSTRAINT `FK_CR_REPORT_REP_ID`
jimmydot3982f4f2017-05-07 14:58:24 -0400234 FOREIGN KEY (`REP_ID`)
235 REFERENCES `vid_openecomp_epsdk`.`cr_report` (`REP_ID`))
236ENGINE = InnoDB
237DEFAULT CHARACTER SET = utf8;
238
239-- ----------------------------------------------------------------------------
240-- Table vid_openecomp_epsdk.cr_report_file_history
241-- ----------------------------------------------------------------------------
242CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_report_file_history` (
243 `HIST_ID` INT(11) NOT NULL,
244 `SCHED_USER_ID` DECIMAL(11,0) NOT NULL,
245 `SCHEDULE_ID` DECIMAL(11,0) NOT NULL,
246 `USER_ID` DECIMAL(11,0) NOT NULL,
247 `REP_ID` DECIMAL(11,0) NULL DEFAULT NULL,
248 `RUN_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
249 `RECURRENCE` VARCHAR(50) NULL DEFAULT NULL,
250 `FILE_TYPE_ID` DECIMAL(2,0) NULL DEFAULT NULL,
251 `FILE_NAME` VARCHAR(80) NULL DEFAULT NULL,
252 `FILE_BLOB` BLOB NULL DEFAULT NULL,
253 `FILE_SIZE` DECIMAL(11,0) NULL DEFAULT NULL,
254 `RAPTOR_URL` VARCHAR(4000) NULL DEFAULT NULL,
255 `ERROR_YN` CHAR(1) NULL DEFAULT 'N',
256 `ERROR_CODE` DECIMAL(11,0) NULL DEFAULT NULL,
257 `DELETED_YN` CHAR(1) NULL DEFAULT 'N',
258 `DELETED_BY` DECIMAL(38,0) NULL DEFAULT NULL,
259 PRIMARY KEY (`HIST_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200260 INDEX `SYS_C0014614` (`FILE_TYPE_ID` ASC),
261 INDEX `SYS_C0014615` (`REP_ID` ASC),
262 CONSTRAINT `SYS_C0014614`
jimmydot3982f4f2017-05-07 14:58:24 -0400263 FOREIGN KEY (`FILE_TYPE_ID`)
264 REFERENCES `vid_openecomp_epsdk`.`cr_lu_file_type` (`LOOKUP_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200265 CONSTRAINT `SYS_C0014615`
jimmydot3982f4f2017-05-07 14:58:24 -0400266 FOREIGN KEY (`REP_ID`)
267 REFERENCES `vid_openecomp_epsdk`.`cr_report` (`REP_ID`))
268ENGINE = InnoDB
269DEFAULT CHARACTER SET = utf8;
270
271-- ----------------------------------------------------------------------------
272-- Table vid_openecomp_epsdk.cr_report_log
273-- ----------------------------------------------------------------------------
274CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_report_log` (
275 `REP_ID` DECIMAL(11,0) NOT NULL,
276 `LOG_TIME` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
277 `USER_ID` DECIMAL(11,0) NOT NULL,
278 `ACTION` VARCHAR(2000) NOT NULL,
279 `ACTION_VALUE` VARCHAR(50) NULL DEFAULT NULL,
280 `FORM_FIELDS` VARCHAR(4000) NULL DEFAULT NULL,
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200281 INDEX `FK_CR_REPOR_REF_17645_CR_REPOR` (`REP_ID` ASC),
282 CONSTRAINT `FK_CR_REPOR_REF_17645_CR_REPOR`
jimmydot3982f4f2017-05-07 14:58:24 -0400283 FOREIGN KEY (`REP_ID`)
284 REFERENCES `vid_openecomp_epsdk`.`cr_report` (`REP_ID`))
285ENGINE = InnoDB
286DEFAULT CHARACTER SET = utf8;
287
288-- ----------------------------------------------------------------------------
289-- Table vid_openecomp_epsdk.cr_report_schedule
290-- ----------------------------------------------------------------------------
291CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_report_schedule` (
292 `SCHEDULE_ID` DECIMAL(11,0) NOT NULL,
293 `SCHED_USER_ID` DECIMAL(11,0) NOT NULL,
294 `REP_ID` DECIMAL(11,0) NOT NULL,
295 `ENABLED_YN` VARCHAR(1) NOT NULL,
296 `START_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
297 `END_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
298 `RUN_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
299 `RECURRENCE` VARCHAR(50) NULL DEFAULT NULL,
300 `CONDITIONAL_YN` VARCHAR(1) NOT NULL,
301 `CONDITION_SQL` VARCHAR(4000) NULL DEFAULT NULL,
302 `NOTIFY_TYPE` INT(11) NULL DEFAULT '0',
303 `MAX_ROW` INT(11) NULL DEFAULT '1000',
304 `INITIAL_FORMFIELDS` VARCHAR(3500) NULL DEFAULT NULL,
305 `PROCESSED_FORMFIELDS` VARCHAR(3500) NULL DEFAULT NULL,
306 `FORMFIELDS` VARCHAR(3500) NULL DEFAULT NULL,
307 `CONDITION_LARGE_SQL` TEXT NULL DEFAULT NULL,
308 `ENCRYPT_YN` CHAR(1) NULL DEFAULT 'N',
309 `ATTACHMENT_YN` CHAR(1) NULL DEFAULT 'Y',
310 PRIMARY KEY (`SCHEDULE_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200311 INDEX `FK_CR_REPOR_REF_14707_CR_REPOR` (`REP_ID` ASC),
312 CONSTRAINT `FK_CR_REPOR_REF_14707_CR_REPOR`
jimmydot3982f4f2017-05-07 14:58:24 -0400313 FOREIGN KEY (`REP_ID`)
314 REFERENCES `vid_openecomp_epsdk`.`cr_report` (`REP_ID`))
315ENGINE = InnoDB
316DEFAULT CHARACTER SET = utf8;
317
318-- ----------------------------------------------------------------------------
319-- Table vid_openecomp_epsdk.cr_report_schedule_users
320-- ----------------------------------------------------------------------------
321CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_report_schedule_users` (
322 `SCHEDULE_ID` DECIMAL(11,0) NOT NULL,
323 `REP_ID` DECIMAL(11,0) NOT NULL,
324 `USER_ID` DECIMAL(11,0) NOT NULL,
325 `ROLE_ID` DECIMAL(11,0) NULL DEFAULT NULL,
326 `ORDER_NO` DECIMAL(11,0) NOT NULL,
327 PRIMARY KEY (`SCHEDULE_ID`, `REP_ID`, `USER_ID`, `ORDER_NO`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200328 CONSTRAINT `FK_CR_REPOR_REF_14716_CR_REPOR`
jimmydot3982f4f2017-05-07 14:58:24 -0400329 FOREIGN KEY (`SCHEDULE_ID`)
330 REFERENCES `vid_openecomp_epsdk`.`cr_report_schedule` (`SCHEDULE_ID`))
331ENGINE = InnoDB
332DEFAULT CHARACTER SET = utf8;
333
334-- ----------------------------------------------------------------------------
335-- Table vid_openecomp_epsdk.cr_report_template_map
336-- ----------------------------------------------------------------------------
337CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_report_template_map` (
338 `REPORT_ID` INT(11) NOT NULL,
339 `TEMPLATE_FILE` VARCHAR(200) NULL DEFAULT NULL,
340 PRIMARY KEY (`REPORT_ID`))
341ENGINE = InnoDB
342DEFAULT CHARACTER SET = utf8;
343
344-- ----------------------------------------------------------------------------
345-- Table vid_openecomp_epsdk.cr_schedule_activity_log
346-- ----------------------------------------------------------------------------
347CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_schedule_activity_log` (
348 `SCHEDULE_ID` DECIMAL(11,0) NOT NULL,
349 `URL` VARCHAR(4000) NULL DEFAULT NULL,
350 `NOTES` VARCHAR(2000) NULL DEFAULT NULL,
351 `RUN_TIME` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP)
352ENGINE = InnoDB
353DEFAULT CHARACTER SET = utf8;
354
355-- ----------------------------------------------------------------------------
356-- Table vid_openecomp_epsdk.cr_table_join
357-- ----------------------------------------------------------------------------
358CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_table_join` (
359 `SRC_TABLE_NAME` VARCHAR(30) NOT NULL,
360 `DEST_TABLE_NAME` VARCHAR(30) NOT NULL,
361 `JOIN_EXPR` VARCHAR(500) NOT NULL,
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200362 INDEX `CR_TABLE_JOIN_DEST_TABLE_NAME` (`DEST_TABLE_NAME` ASC),
363 INDEX `CR_TABLE_JOIN_SRC_TABLE_NAME` (`SRC_TABLE_NAME` ASC),
364 CONSTRAINT `FK_CR_TABLE_REF_311_CR_TAB`
jimmydot3982f4f2017-05-07 14:58:24 -0400365 FOREIGN KEY (`SRC_TABLE_NAME`)
366 REFERENCES `vid_openecomp_epsdk`.`cr_table_source` (`TABLE_NAME`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200367 CONSTRAINT `FK_CR_TABLE_REF_315_CR_TAB`
jimmydot3982f4f2017-05-07 14:58:24 -0400368 FOREIGN KEY (`DEST_TABLE_NAME`)
369 REFERENCES `vid_openecomp_epsdk`.`cr_table_source` (`TABLE_NAME`))
370ENGINE = InnoDB
371DEFAULT CHARACTER SET = utf8;
372
373-- ----------------------------------------------------------------------------
374-- Table vid_openecomp_epsdk.cr_table_role
375-- ----------------------------------------------------------------------------
376CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_table_role` (
377 `TABLE_NAME` VARCHAR(30) NOT NULL,
378 `ROLE_ID` DECIMAL(11,0) NOT NULL,
379 PRIMARY KEY (`TABLE_NAME`, `ROLE_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200380 CONSTRAINT `FK_CR_TABLE_REF_32384_CR_TABLE`
jimmydot3982f4f2017-05-07 14:58:24 -0400381 FOREIGN KEY (`TABLE_NAME`)
382 REFERENCES `vid_openecomp_epsdk`.`cr_table_source` (`TABLE_NAME`))
383ENGINE = InnoDB
384DEFAULT CHARACTER SET = utf8;
385
386-- ----------------------------------------------------------------------------
387-- Table vid_openecomp_epsdk.cr_table_source
388-- ----------------------------------------------------------------------------
389CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`cr_table_source` (
390 `TABLE_NAME` VARCHAR(30) NOT NULL,
391 `DISPLAY_NAME` VARCHAR(30) NOT NULL,
392 `PK_FIELDS` VARCHAR(200) NULL DEFAULT NULL,
393 `WEB_VIEW_ACTION` VARCHAR(50) NULL DEFAULT NULL,
394 `LARGE_DATA_SOURCE_YN` VARCHAR(1) NOT NULL DEFAULT 'N',
395 `FILTER_SQL` VARCHAR(4000) NULL DEFAULT NULL,
396 `SOURCE_DB` VARCHAR(50) NULL DEFAULT NULL,
397 PRIMARY KEY (`TABLE_NAME`))
398ENGINE = InnoDB
399DEFAULT CHARACTER SET = utf8;
400
401-- ----------------------------------------------------------------------------
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200402-- Table vid_portal.fn_app
jimmydot3982f4f2017-05-07 14:58:24 -0400403-- ----------------------------------------------------------------------------
404CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_app` (
405 `APP_ID` INT(11) NOT NULL AUTO_INCREMENT,
406 `APP_NAME` VARCHAR(100) NOT NULL DEFAULT '?',
407 `APP_IMAGE_URL` VARCHAR(256) NULL DEFAULT NULL,
408 `APP_DESCRIPTION` VARCHAR(512) NULL DEFAULT NULL,
409 `APP_NOTES` VARCHAR(4096) NULL DEFAULT NULL,
410 `APP_URL` VARCHAR(256) NULL DEFAULT NULL,
411 `APP_ALTERNATE_URL` VARCHAR(256) NULL DEFAULT NULL,
412 `APP_REST_ENDPOINT` VARCHAR(2000) NULL DEFAULT NULL,
413 `ML_APP_NAME` VARCHAR(50) NOT NULL DEFAULT '?',
414 `ML_APP_ADMIN_ID` VARCHAR(7) NOT NULL DEFAULT '?',
415 `MOTS_ID` INT(11) NULL DEFAULT NULL,
416 `APP_PASSWORD` VARCHAR(256) NOT NULL DEFAULT '?',
417 `OPEN` CHAR(1) NULL DEFAULT 'N',
418 `ENABLED` CHAR(1) NULL DEFAULT 'Y',
419 `THUMBNAIL` MEDIUMBLOB NULL DEFAULT NULL,
420 `APP_USERNAME` VARCHAR(50) NULL DEFAULT NULL,
421 `UEB_KEY` VARCHAR(256) NULL DEFAULT NULL,
422 `UEB_SECRET` VARCHAR(256) NULL DEFAULT NULL,
423 `UEB_TOPIC_NAME` VARCHAR(256) NULL DEFAULT NULL,
424 PRIMARY KEY (`APP_ID`))
425ENGINE = InnoDB
426AUTO_INCREMENT = 2
427DEFAULT CHARACTER SET = utf8;
428
429-- ----------------------------------------------------------------------------
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200430-- Table vid_openecomp_epsdk.fn_app_mme_cpu
431-- ----------------------------------------------------------------------------
432CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_app_mme_cpu` (
433 `MME` VARCHAR(200) NULL DEFAULT NULL,
434 `YEARMONTH` INT(11) NULL DEFAULT NULL,
435 `SCTP_CPU` INT(11) NULL DEFAULT NULL,
436 `AP_CPU` INT(11) NULL DEFAULT NULL,
437 `DP_CPU` INT(11) NULL DEFAULT NULL,
438 `ROUTER_CPU` INT(11) NULL DEFAULT NULL,
439 `PEB_CPU` INT(11) NULL DEFAULT NULL,
440 `SAU` INT(11) NULL DEFAULT NULL)
441ENGINE = InnoDB
442DEFAULT CHARACTER SET = utf8;
443
444-- ----------------------------------------------------------------------------
jimmydot3982f4f2017-05-07 14:58:24 -0400445-- Table vid_openecomp_epsdk.fn_audit_action
446-- ----------------------------------------------------------------------------
447CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_audit_action` (
448 `AUDIT_ACTION_ID` INT(11) NOT NULL,
449 `CLASS_NAME` VARCHAR(500) NOT NULL,
450 `METHOD_NAME` VARCHAR(50) NOT NULL,
451 `AUDIT_ACTION_CD` VARCHAR(20) NOT NULL,
452 `AUDIT_ACTION_DESC` VARCHAR(200) NULL DEFAULT NULL,
453 `ACTIVE_YN` VARCHAR(1) NULL DEFAULT NULL,
454 PRIMARY KEY (`AUDIT_ACTION_ID`))
455ENGINE = InnoDB
456DEFAULT CHARACTER SET = utf8;
457
458-- ----------------------------------------------------------------------------
459-- Table vid_openecomp_epsdk.fn_audit_action_log
460-- ----------------------------------------------------------------------------
461CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_audit_action_log` (
462 `AUDIT_LOG_ID` INT(11) NOT NULL AUTO_INCREMENT,
463 `AUDIT_ACTION_CD` VARCHAR(200) NULL DEFAULT NULL,
464 `ACTION_TIME` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
465 `USER_ID` DECIMAL(11,0) NULL DEFAULT NULL,
466 `CLASS_NAME` VARCHAR(100) NULL DEFAULT NULL,
467 `METHOD_NAME` VARCHAR(50) NULL DEFAULT NULL,
468 `SUCCESS_MSG` VARCHAR(20) NULL DEFAULT NULL,
469 `ERROR_MSG` VARCHAR(500) NULL DEFAULT NULL,
470 PRIMARY KEY (`AUDIT_LOG_ID`))
471ENGINE = InnoDB
472DEFAULT CHARACTER SET = utf8;
473
474-- ----------------------------------------------------------------------------
475-- Table vid_openecomp_epsdk.fn_audit_log
476-- ----------------------------------------------------------------------------
477CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_audit_log` (
478 `LOG_ID` INT(11) NOT NULL AUTO_INCREMENT,
479 `USER_ID` INT(11) NOT NULL,
480 `ACTIVITY_CD` VARCHAR(50) NOT NULL,
481 `AUDIT_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
482 `COMMENTS` VARCHAR(1000) NULL DEFAULT NULL,
483 `AFFECTED_RECORD_ID_BK` VARCHAR(500) NULL DEFAULT NULL,
484 `AFFECTED_RECORD_ID` VARCHAR(4000) NULL DEFAULT NULL,
485 PRIMARY KEY (`LOG_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200486 INDEX `FN_AUDIT_LOG_ACTIVITY_CD` (`ACTIVITY_CD` ASC),
487 INDEX `FN_AUDIT_LOG_USER_ID` (`USER_ID` ASC),
488 CONSTRAINT `FK_FN_AUDIT_REF_205_FN_LU_AC`
489 FOREIGN KEY (`ACTIVITY_CD`)
490 REFERENCES `vid_openecomp_epsdk`.`fn_lu_activity` (`ACTIVITY_CD`),
jimmydot3982f4f2017-05-07 14:58:24 -0400491 CONSTRAINT `FK_FN_AUDIT_REF_209_FN_USER`
492 FOREIGN KEY (`USER_ID`)
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200493 REFERENCES `vid_openecomp_epsdk`.`fn_user` (`USER_ID`))
jimmydot3982f4f2017-05-07 14:58:24 -0400494ENGINE = InnoDB
495DEFAULT CHARACTER SET = utf8;
496
497-- ----------------------------------------------------------------------------
498-- Table vid_openecomp_epsdk.fn_broadcast_message
499-- ----------------------------------------------------------------------------
500CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_broadcast_message` (
501 `MESSAGE_ID` INT(11) NOT NULL AUTO_INCREMENT,
502 `MESSAGE_TEXT` VARCHAR(1000) NOT NULL,
503 `MESSAGE_LOCATION_ID` DECIMAL(11,0) NOT NULL,
504 `BROADCAST_START_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
505 `BROADCAST_END_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
506 `ACTIVE_YN` CHAR(1) NOT NULL DEFAULT 'Y',
507 `SORT_ORDER` DECIMAL(4,0) NOT NULL,
508 `BROADCAST_SITE_CD` VARCHAR(50) NULL DEFAULT NULL,
509 PRIMARY KEY (`MESSAGE_ID`))
510ENGINE = InnoDB
511DEFAULT CHARACTER SET = utf8;
512
513-- ----------------------------------------------------------------------------
514-- Table vid_openecomp_epsdk.fn_chat_logs
515-- ----------------------------------------------------------------------------
516CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_chat_logs` (
517 `CHAT_LOG_ID` INT(11) NOT NULL,
518 `CHAT_ROOM_ID` INT(11) NULL DEFAULT NULL,
519 `USER_ID` INT(11) NULL DEFAULT NULL,
520 `MESSAGE` VARCHAR(1000) NULL DEFAULT NULL,
521 `MESSAGE_DATE_TIME` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
522 PRIMARY KEY (`CHAT_LOG_ID`))
523ENGINE = InnoDB
524DEFAULT CHARACTER SET = utf8;
525
526-- ----------------------------------------------------------------------------
527-- Table vid_openecomp_epsdk.fn_chat_room
528-- ----------------------------------------------------------------------------
529CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_chat_room` (
530 `CHAT_ROOM_ID` INT(11) NOT NULL,
531 `NAME` VARCHAR(50) NOT NULL,
532 `DESCRIPTION` VARCHAR(500) NULL DEFAULT NULL,
533 `OWNER_ID` INT(11) NULL DEFAULT NULL,
534 `CREATED_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
535 `UPDATED_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
536 PRIMARY KEY (`CHAT_ROOM_ID`))
537ENGINE = InnoDB
538DEFAULT CHARACTER SET = utf8;
539
540-- ----------------------------------------------------------------------------
541-- Table vid_openecomp_epsdk.fn_chat_users
542-- ----------------------------------------------------------------------------
543CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_chat_users` (
544 `CHAT_ROOM_ID` INT(11) NULL DEFAULT NULL,
545 `USER_ID` INT(11) NULL DEFAULT NULL,
546 `LAST_ACTIVITY_DATE_TIME` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
547 `CHAT_STATUS` VARCHAR(20) NULL DEFAULT NULL,
548 `ID` INT(11) NOT NULL,
549 PRIMARY KEY (`ID`))
550ENGINE = InnoDB
551DEFAULT CHARACTER SET = utf8;
552
553-- ----------------------------------------------------------------------------
554-- Table vid_openecomp_epsdk.fn_datasource
555-- ----------------------------------------------------------------------------
556CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_datasource` (
557 `ID` INT(11) NOT NULL AUTO_INCREMENT,
558 `NAME` VARCHAR(50) NULL DEFAULT NULL,
559 `DRIVER_NAME` VARCHAR(256) NULL DEFAULT NULL,
560 `SERVER` VARCHAR(256) NULL DEFAULT NULL,
561 `PORT` INT(11) NULL DEFAULT NULL,
562 `USER_NAME` VARCHAR(256) NULL DEFAULT NULL,
563 `PASSWORD` VARCHAR(256) NULL DEFAULT NULL,
564 `URL` VARCHAR(256) NULL DEFAULT NULL,
565 `MIN_POOL_SIZE` INT(11) NULL DEFAULT NULL,
566 `MAX_POOL_SIZE` INT(11) NULL DEFAULT NULL,
567 `ADAPTER_ID` INT(11) NULL DEFAULT NULL,
568 `DS_TYPE` VARCHAR(20) NULL DEFAULT NULL,
569 PRIMARY KEY (`ID`))
570ENGINE = InnoDB
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200571AUTO_INCREMENT = 4
jimmydot3982f4f2017-05-07 14:58:24 -0400572DEFAULT CHARACTER SET = utf8;
573
574-- ----------------------------------------------------------------------------
575-- Table vid_openecomp_epsdk.fn_function
576-- ----------------------------------------------------------------------------
577CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_function` (
578 `FUNCTION_CD` VARCHAR(30) NOT NULL,
579 `FUNCTION_NAME` VARCHAR(50) NOT NULL,
Sonsino, Ofir (os0695)7059a9c2018-09-05 16:06:16 +0300580 `type` VARCHAR(20) NOT NULL,
581 `action` VARCHAR(20) NOT NULL,
582 PRIMARY KEY (`FUNCTION_CD`),
583 CONSTRAINT `function` UNIQUE (FUNCTION_CD,TYPE,ACTION))
jimmydot3982f4f2017-05-07 14:58:24 -0400584ENGINE = InnoDB
585DEFAULT CHARACTER SET = utf8;
586
587-- ----------------------------------------------------------------------------
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200588-- Table vid_openecomp_epsdk.fn_license
589-- ----------------------------------------------------------------------------
590CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_license` (
591 `id` DECIMAL(11,0) NOT NULL,
592 `app_id` DECIMAL(11,0) NOT NULL,
593 `ip_address` VARCHAR(100) NOT NULL,
594 `quantum_version_id` DECIMAL(11,0) NOT NULL,
595 `created_date` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
596 `modified_date` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
597 `created_id` DECIMAL(11,0) NULL DEFAULT NULL,
598 `modified_id` DECIMAL(11,0) NULL DEFAULT NULL,
599 `end_date` TIMESTAMP NOT NULL DEFAULT '2036-01-19 03:14:07',
600 PRIMARY KEY (`id`),
601 INDEX `fn_license_r02` (`quantum_version_id` ASC),
602 CONSTRAINT `fn_license_r02`
603 FOREIGN KEY (`quantum_version_id`)
604 REFERENCES `vid_openecomp_epsdk`.`fn_license_version` (`id`))
605ENGINE = InnoDB
606DEFAULT CHARACTER SET = utf8;
607
608-- ----------------------------------------------------------------------------
609-- Table vid_openecomp_epsdk.fn_license_app
610-- ----------------------------------------------------------------------------
611CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_license_app` (
612 `id` DECIMAL(11,0) NOT NULL,
613 `app_name` VARCHAR(100) NOT NULL,
614 `ctxt_name` VARCHAR(100) NULL DEFAULT NULL,
615 INDEX `fn_license_app_ID` (`id` ASC))
616ENGINE = InnoDB
617DEFAULT CHARACTER SET = utf8;
618
619-- ----------------------------------------------------------------------------
620-- Table vid_openecomp_epsdk.fn_license_contact
621-- ----------------------------------------------------------------------------
622CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_license_contact` (
623 `id` INT(11) NOT NULL,
624 `license_id` INT(11) NULL DEFAULT NULL,
625 `sbcid` VARCHAR(20) NULL DEFAULT NULL,
626 PRIMARY KEY (`id`))
627ENGINE = InnoDB
628DEFAULT CHARACTER SET = utf8;
629
630-- ----------------------------------------------------------------------------
631-- Table vid_openecomp_epsdk.fn_license_history
632-- ----------------------------------------------------------------------------
633CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_license_history` (
634 `license_id` DECIMAL(11,0) NULL DEFAULT NULL,
635 `app_id` DECIMAL(11,0) NULL DEFAULT NULL,
636 `ip_address` VARCHAR(100) NULL DEFAULT NULL,
637 `quantum_version_id` DECIMAL(11,0) NULL DEFAULT NULL,
638 `created_date` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
639 `modified_date` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
640 `created_id` DECIMAL(11,0) NULL DEFAULT NULL,
641 `modified_id` DECIMAL(11,0) NULL DEFAULT NULL,
642 `id` DECIMAL(11,0) NOT NULL,
643 PRIMARY KEY (`id`))
644ENGINE = InnoDB
645DEFAULT CHARACTER SET = utf8;
646
647-- ----------------------------------------------------------------------------
648-- Table vid_openecomp_epsdk.fn_license_version
649-- ----------------------------------------------------------------------------
650CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_license_version` (
651 `id` DECIMAL(11,0) NOT NULL,
652 `quantum_version` VARCHAR(25) NULL DEFAULT NULL,
653 PRIMARY KEY (`id`))
654ENGINE = InnoDB
655DEFAULT CHARACTER SET = utf8;
656
657-- ----------------------------------------------------------------------------
jimmydot3982f4f2017-05-07 14:58:24 -0400658-- Table vid_openecomp_epsdk.fn_lu_activity
659-- ----------------------------------------------------------------------------
660CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_lu_activity` (
661 `ACTIVITY_CD` VARCHAR(50) NOT NULL,
662 `ACTIVITY` VARCHAR(50) NOT NULL,
663 PRIMARY KEY (`ACTIVITY_CD`))
664ENGINE = InnoDB
665DEFAULT CHARACTER SET = utf8;
666
667-- ----------------------------------------------------------------------------
668-- Table vid_openecomp_epsdk.fn_lu_alert_method
669-- ----------------------------------------------------------------------------
670CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_lu_alert_method` (
671 `ALERT_METHOD_CD` VARCHAR(10) NOT NULL,
672 `ALERT_METHOD` VARCHAR(50) NOT NULL,
673 PRIMARY KEY (`ALERT_METHOD_CD`))
674ENGINE = InnoDB
675DEFAULT CHARACTER SET = utf8;
676
677-- ----------------------------------------------------------------------------
678-- Table vid_openecomp_epsdk.fn_lu_broadcast_site
679-- ----------------------------------------------------------------------------
680CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_lu_broadcast_site` (
681 `BROADCAST_SITE_CD` VARCHAR(50) NOT NULL,
682 `BROADCAST_SITE_DESCR` VARCHAR(100) NULL DEFAULT NULL,
683 PRIMARY KEY (`BROADCAST_SITE_CD`))
684ENGINE = InnoDB
685DEFAULT CHARACTER SET = utf8;
686
687-- ----------------------------------------------------------------------------
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200688-- Table vid_openecomp_epsdk.fn_lu_call_times
689-- ----------------------------------------------------------------------------
690CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_lu_call_times` (
691 `CALL_TIME_ID` DECIMAL(10,0) NOT NULL,
692 `CALL_TIME_AMOUNT` DECIMAL(10,0) NOT NULL,
693 `CALL_TIME_DISPLAY` VARCHAR(50) NOT NULL,
694 PRIMARY KEY (`CALL_TIME_ID`))
695ENGINE = InnoDB
696DEFAULT CHARACTER SET = utf8;
697
698-- ----------------------------------------------------------------------------
699-- Table vid_openecomp_epsdk.fn_lu_city
700-- ----------------------------------------------------------------------------
701CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_lu_city` (
702 `CITY_CD` VARCHAR(2) NOT NULL,
703 `CITY` VARCHAR(100) NOT NULL,
704 `STATE_CD` VARCHAR(2) NOT NULL,
705 PRIMARY KEY (`CITY_CD`, `STATE_CD`))
706ENGINE = InnoDB
707DEFAULT CHARACTER SET = utf8;
708
709-- ----------------------------------------------------------------------------
710-- Table vid_openecomp_epsdk.fn_lu_country
711-- ----------------------------------------------------------------------------
712CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_lu_country` (
713 `COUNTRY_CD` VARCHAR(3) NOT NULL,
714 `COUNTRY` VARCHAR(100) NOT NULL,
715 `FULL_NAME` VARCHAR(100) NULL DEFAULT NULL,
716 `WEBPHONE_COUNTRY_LABEL` VARCHAR(30) NULL DEFAULT NULL,
717 PRIMARY KEY (`COUNTRY_CD`))
718ENGINE = InnoDB
719DEFAULT CHARACTER SET = utf8;
720
721-- ----------------------------------------------------------------------------
jimmydot3982f4f2017-05-07 14:58:24 -0400722-- Table vid_openecomp_epsdk.fn_lu_menu_set
723-- ----------------------------------------------------------------------------
724CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_lu_menu_set` (
725 `MENU_SET_CD` VARCHAR(10) NOT NULL,
726 `MENU_SET_NAME` VARCHAR(50) NOT NULL,
727 PRIMARY KEY (`MENU_SET_CD`))
728ENGINE = InnoDB
729DEFAULT CHARACTER SET = utf8;
730
731-- ----------------------------------------------------------------------------
jimmydot3982f4f2017-05-07 14:58:24 -0400732-- Table vid_openecomp_epsdk.fn_lu_priority
733-- ----------------------------------------------------------------------------
734CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_lu_priority` (
735 `PRIORITY_ID` DECIMAL(11,0) NOT NULL,
736 `PRIORITY` VARCHAR(50) NOT NULL,
737 `ACTIVE_YN` CHAR(1) NOT NULL,
738 `SORT_ORDER` DECIMAL(5,0) NULL DEFAULT NULL,
739 PRIMARY KEY (`PRIORITY_ID`))
740ENGINE = InnoDB
741DEFAULT CHARACTER SET = utf8;
742
743-- ----------------------------------------------------------------------------
744-- Table vid_openecomp_epsdk.fn_lu_role_type
745-- ----------------------------------------------------------------------------
746CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_lu_role_type` (
747 `ROLE_TYPE_ID` DECIMAL(11,0) NOT NULL,
748 `ROLE_TYPE` VARCHAR(50) NOT NULL,
749 PRIMARY KEY (`ROLE_TYPE_ID`))
750ENGINE = InnoDB
751DEFAULT CHARACTER SET = utf8;
752
753-- ----------------------------------------------------------------------------
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200754-- Table vid_openecomp_epsdk.fn_lu_state
755-- ----------------------------------------------------------------------------
756CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_lu_state` (
757 `STATE_CD` VARCHAR(2) NOT NULL,
758 `STATE` VARCHAR(100) NOT NULL,
759 PRIMARY KEY (`STATE_CD`))
760ENGINE = InnoDB
761DEFAULT CHARACTER SET = utf8;
762
763-- ----------------------------------------------------------------------------
jimmydot3982f4f2017-05-07 14:58:24 -0400764-- Table vid_openecomp_epsdk.fn_lu_tab_set
765-- ----------------------------------------------------------------------------
766CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_lu_tab_set` (
767 `TAB_SET_CD` VARCHAR(30) NOT NULL,
768 `TAB_SET_NAME` VARCHAR(50) NOT NULL,
769 PRIMARY KEY (`TAB_SET_CD`))
770ENGINE = InnoDB
771DEFAULT CHARACTER SET = utf8;
772
773-- ----------------------------------------------------------------------------
774-- Table vid_openecomp_epsdk.fn_lu_timezone
775-- ----------------------------------------------------------------------------
776CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_lu_timezone` (
777 `TIMEZONE_ID` INT(11) NOT NULL,
778 `TIMEZONE_NAME` VARCHAR(100) NOT NULL,
779 `TIMEZONE_VALUE` VARCHAR(100) NOT NULL,
780 PRIMARY KEY (`TIMEZONE_ID`))
781ENGINE = InnoDB
782DEFAULT CHARACTER SET = utf8;
783
784-- ----------------------------------------------------------------------------
785-- Table vid_openecomp_epsdk.fn_menu
786-- ----------------------------------------------------------------------------
787CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_menu` (
788 `MENU_ID` INT(11) NOT NULL AUTO_INCREMENT,
789 `LABEL` VARCHAR(100) NULL DEFAULT NULL,
790 `PARENT_ID` INT(11) NULL DEFAULT NULL,
791 `SORT_ORDER` DECIMAL(4,0) NULL DEFAULT NULL,
792 `ACTION` VARCHAR(200) NULL DEFAULT NULL,
793 `FUNCTION_CD` VARCHAR(30) NULL DEFAULT NULL,
794 `ACTIVE_YN` VARCHAR(1) NOT NULL DEFAULT 'Y',
795 `SERVLET` VARCHAR(50) NULL DEFAULT NULL,
796 `QUERY_STRING` VARCHAR(200) NULL DEFAULT NULL,
797 `EXTERNAL_URL` VARCHAR(200) NULL DEFAULT NULL,
798 `TARGET` VARCHAR(25) NULL DEFAULT NULL,
799 `MENU_SET_CD` VARCHAR(10) NULL DEFAULT 'APP',
800 `SEPARATOR_YN` CHAR(1) NULL DEFAULT 'N',
801 `IMAGE_SRC` VARCHAR(100) NULL DEFAULT NULL,
802 PRIMARY KEY (`MENU_ID`),
803 INDEX `FK_FN_MENU_REF_196_FN_MENU` (`PARENT_ID` ASC),
804 INDEX `FK_FN_MENU_MENU_SET_CD` (`MENU_SET_CD` ASC),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200805 INDEX `FN_MENU_FUNCTION_CD` (`FUNCTION_CD` ASC),
jimmydot3982f4f2017-05-07 14:58:24 -0400806 CONSTRAINT `FK_FN_MENU_MENU_SET_CD`
807 FOREIGN KEY (`MENU_SET_CD`)
808 REFERENCES `vid_openecomp_epsdk`.`fn_lu_menu_set` (`MENU_SET_CD`),
809 CONSTRAINT `FK_FN_MENU_REF_196_FN_MENU`
810 FOREIGN KEY (`PARENT_ID`)
811 REFERENCES `vid_openecomp_epsdk`.`fn_menu` (`MENU_ID`),
812 CONSTRAINT `FK_FN_MENU_REF_223_FN_FUNCT`
813 FOREIGN KEY (`FUNCTION_CD`)
814 REFERENCES `vid_openecomp_epsdk`.`fn_function` (`FUNCTION_CD`))
815ENGINE = InnoDB
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200816AUTO_INCREMENT = 150029
jimmydot3982f4f2017-05-07 14:58:24 -0400817DEFAULT CHARACTER SET = utf8;
818
819-- ----------------------------------------------------------------------------
820-- Table vid_openecomp_epsdk.fn_org
821-- ----------------------------------------------------------------------------
822CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_org` (
823 `ORG_ID` INT(11) NOT NULL,
824 `ORG_NAME` VARCHAR(50) NOT NULL,
825 `ACCESS_CD` VARCHAR(10) NULL DEFAULT NULL,
826 PRIMARY KEY (`ORG_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200827 INDEX `FN_ORG_ACCESS_CD` (`ACCESS_CD` ASC))
jimmydot3982f4f2017-05-07 14:58:24 -0400828ENGINE = InnoDB
829DEFAULT CHARACTER SET = utf8;
830
831-- ----------------------------------------------------------------------------
832-- Table vid_openecomp_epsdk.fn_qz_blob_triggers
833-- ----------------------------------------------------------------------------
834CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_qz_blob_triggers` (
835 `SCHED_NAME` VARCHAR(120) NOT NULL,
836 `TRIGGER_NAME` VARCHAR(200) NOT NULL,
837 `TRIGGER_GROUP` VARCHAR(200) NOT NULL,
838 `BLOB_DATA` BLOB NULL DEFAULT NULL,
839 PRIMARY KEY (`SCHED_NAME`, `TRIGGER_NAME`, `TRIGGER_GROUP`),
840 INDEX `SCHED_NAME` (`SCHED_NAME` ASC, `TRIGGER_NAME` ASC, `TRIGGER_GROUP` ASC),
841 CONSTRAINT `fn_qz_blob_triggers_ibfk_1`
842 FOREIGN KEY (`SCHED_NAME` , `TRIGGER_NAME` , `TRIGGER_GROUP`)
843 REFERENCES `vid_openecomp_epsdk`.`fn_qz_triggers` (`SCHED_NAME` , `TRIGGER_NAME` , `TRIGGER_GROUP`))
844ENGINE = InnoDB
845DEFAULT CHARACTER SET = utf8;
846
847-- ----------------------------------------------------------------------------
848-- Table vid_openecomp_epsdk.fn_qz_calendars
849-- ----------------------------------------------------------------------------
850CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_qz_calendars` (
851 `SCHED_NAME` VARCHAR(120) NOT NULL,
852 `CALENDAR_NAME` VARCHAR(200) NOT NULL,
853 `CALENDAR` BLOB NOT NULL,
854 PRIMARY KEY (`SCHED_NAME`, `CALENDAR_NAME`))
855ENGINE = InnoDB
856DEFAULT CHARACTER SET = utf8;
857
858-- ----------------------------------------------------------------------------
859-- Table vid_openecomp_epsdk.fn_qz_cron_triggers
860-- ----------------------------------------------------------------------------
861CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_qz_cron_triggers` (
862 `SCHED_NAME` VARCHAR(120) NOT NULL,
863 `TRIGGER_NAME` VARCHAR(200) NOT NULL,
864 `TRIGGER_GROUP` VARCHAR(200) NOT NULL,
865 `CRON_EXPRESSION` VARCHAR(120) NOT NULL,
866 `TIME_ZONE_ID` VARCHAR(80) NULL DEFAULT NULL,
867 PRIMARY KEY (`SCHED_NAME`, `TRIGGER_NAME`, `TRIGGER_GROUP`),
868 CONSTRAINT `fn_qz_cron_triggers_ibfk_1`
869 FOREIGN KEY (`SCHED_NAME` , `TRIGGER_NAME` , `TRIGGER_GROUP`)
870 REFERENCES `vid_openecomp_epsdk`.`fn_qz_triggers` (`SCHED_NAME` , `TRIGGER_NAME` , `TRIGGER_GROUP`))
871ENGINE = InnoDB
872DEFAULT CHARACTER SET = utf8;
873
874-- ----------------------------------------------------------------------------
875-- Table vid_openecomp_epsdk.fn_qz_fired_triggers
876-- ----------------------------------------------------------------------------
877CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_qz_fired_triggers` (
878 `SCHED_NAME` VARCHAR(120) NOT NULL,
879 `ENTRY_ID` VARCHAR(95) NOT NULL,
880 `TRIGGER_NAME` VARCHAR(200) NOT NULL,
881 `TRIGGER_GROUP` VARCHAR(200) NOT NULL,
882 `INSTANCE_NAME` VARCHAR(200) NOT NULL,
883 `FIRED_TIME` BIGINT(13) NOT NULL,
884 `SCHED_TIME` BIGINT(13) NOT NULL,
885 `PRIORITY` INT(11) NOT NULL,
886 `STATE` VARCHAR(16) NOT NULL,
887 `JOB_NAME` VARCHAR(200) NULL DEFAULT NULL,
888 `JOB_GROUP` VARCHAR(200) NULL DEFAULT NULL,
889 `IS_NONCONCURRENT` VARCHAR(1) NULL DEFAULT NULL,
890 `REQUESTS_RECOVERY` VARCHAR(1) NULL DEFAULT NULL,
891 PRIMARY KEY (`SCHED_NAME`, `ENTRY_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200892 INDEX `IDX_FN_QZ_FT_TRIG_INST_NAME` (`SCHED_NAME` ASC, `INSTANCE_NAME` ASC),
893 INDEX `IDX_FN_QZ_FT_INST_JOB_REQ_RCVRY` (`SCHED_NAME` ASC, `INSTANCE_NAME` ASC, `REQUESTS_RECOVERY` ASC),
894 INDEX `IDX_FN_QZ_FT_J_G` (`SCHED_NAME` ASC, `JOB_NAME` ASC, `JOB_GROUP` ASC),
895 INDEX `IDX_FN_QZ_FT_JG` (`SCHED_NAME` ASC, `JOB_GROUP` ASC),
896 INDEX `IDX_FN_QZ_FT_T_G` (`SCHED_NAME` ASC, `TRIGGER_NAME` ASC, `TRIGGER_GROUP` ASC),
897 INDEX `IDX_FN_QZ_FT_TG` (`SCHED_NAME` ASC, `TRIGGER_GROUP` ASC))
jimmydot3982f4f2017-05-07 14:58:24 -0400898ENGINE = InnoDB
899DEFAULT CHARACTER SET = utf8;
900
901-- ----------------------------------------------------------------------------
902-- Table vid_openecomp_epsdk.fn_qz_job_details
903-- ----------------------------------------------------------------------------
904CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_qz_job_details` (
905 `SCHED_NAME` VARCHAR(120) NOT NULL,
906 `JOB_NAME` VARCHAR(200) NOT NULL,
907 `JOB_GROUP` VARCHAR(200) NOT NULL,
908 `DESCRIPTION` VARCHAR(250) NULL DEFAULT NULL,
909 `JOB_CLASS_NAME` VARCHAR(250) NOT NULL,
910 `IS_DURABLE` VARCHAR(1) NOT NULL,
911 `IS_NONCONCURRENT` VARCHAR(1) NOT NULL,
912 `IS_UPDATE_DATA` VARCHAR(1) NOT NULL,
913 `REQUESTS_RECOVERY` VARCHAR(1) NOT NULL,
914 `JOB_DATA` BLOB NULL DEFAULT NULL,
915 PRIMARY KEY (`SCHED_NAME`, `JOB_NAME`, `JOB_GROUP`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +0200916 INDEX `IDX_FN_QZ_J_REQ_RECOVERY` (`SCHED_NAME` ASC, `REQUESTS_RECOVERY` ASC),
917 INDEX `IDX_FN_QZ_J_GRP` (`SCHED_NAME` ASC, `JOB_GROUP` ASC))
jimmydot3982f4f2017-05-07 14:58:24 -0400918ENGINE = InnoDB
919DEFAULT CHARACTER SET = utf8;
920
921-- ----------------------------------------------------------------------------
922-- Table vid_openecomp_epsdk.fn_qz_locks
923-- ----------------------------------------------------------------------------
924CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_qz_locks` (
925 `SCHED_NAME` VARCHAR(120) NOT NULL,
926 `LOCK_NAME` VARCHAR(40) NOT NULL,
927 PRIMARY KEY (`SCHED_NAME`, `LOCK_NAME`))
928ENGINE = InnoDB
929DEFAULT CHARACTER SET = utf8;
930
931-- ----------------------------------------------------------------------------
932-- Table vid_openecomp_epsdk.fn_qz_paused_trigger_grps
933-- ----------------------------------------------------------------------------
934CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_qz_paused_trigger_grps` (
935 `SCHED_NAME` VARCHAR(120) NOT NULL,
936 `TRIGGER_GROUP` VARCHAR(200) NOT NULL,
937 PRIMARY KEY (`SCHED_NAME`, `TRIGGER_GROUP`))
938ENGINE = InnoDB
939DEFAULT CHARACTER SET = utf8;
940
941-- ----------------------------------------------------------------------------
942-- Table vid_openecomp_epsdk.fn_qz_scheduler_state
943-- ----------------------------------------------------------------------------
944CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_qz_scheduler_state` (
945 `SCHED_NAME` VARCHAR(120) NOT NULL,
946 `INSTANCE_NAME` VARCHAR(200) NOT NULL,
947 `LAST_CHECKIN_TIME` BIGINT(13) NOT NULL,
948 `CHECKIN_INTERVAL` BIGINT(13) NOT NULL,
949 PRIMARY KEY (`SCHED_NAME`, `INSTANCE_NAME`))
950ENGINE = InnoDB
951DEFAULT CHARACTER SET = utf8;
952
953-- ----------------------------------------------------------------------------
954-- Table vid_openecomp_epsdk.fn_qz_simple_triggers
955-- ----------------------------------------------------------------------------
956CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_qz_simple_triggers` (
957 `SCHED_NAME` VARCHAR(120) NOT NULL,
958 `TRIGGER_NAME` VARCHAR(200) NOT NULL,
959 `TRIGGER_GROUP` VARCHAR(200) NOT NULL,
960 `REPEAT_COUNT` BIGINT(7) NOT NULL,
961 `REPEAT_INTERVAL` BIGINT(12) NOT NULL,
962 `TIMES_TRIGGERED` BIGINT(10) NOT NULL,
963 PRIMARY KEY (`SCHED_NAME`, `TRIGGER_NAME`, `TRIGGER_GROUP`),
964 CONSTRAINT `fn_qz_simple_triggers_ibfk_1`
965 FOREIGN KEY (`SCHED_NAME` , `TRIGGER_NAME` , `TRIGGER_GROUP`)
966 REFERENCES `vid_openecomp_epsdk`.`fn_qz_triggers` (`SCHED_NAME` , `TRIGGER_NAME` , `TRIGGER_GROUP`))
967ENGINE = InnoDB
968DEFAULT CHARACTER SET = utf8;
969
970-- ----------------------------------------------------------------------------
971-- Table vid_openecomp_epsdk.fn_qz_simprop_triggers
972-- ----------------------------------------------------------------------------
973CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_qz_simprop_triggers` (
974 `SCHED_NAME` VARCHAR(120) NOT NULL,
975 `TRIGGER_NAME` VARCHAR(200) NOT NULL,
976 `TRIGGER_GROUP` VARCHAR(200) NOT NULL,
977 `STR_PROP_1` VARCHAR(512) NULL DEFAULT NULL,
978 `STR_PROP_2` VARCHAR(512) NULL DEFAULT NULL,
979 `STR_PROP_3` VARCHAR(512) NULL DEFAULT NULL,
980 `INT_PROP_1` INT(11) NULL DEFAULT NULL,
981 `INT_PROP_2` INT(11) NULL DEFAULT NULL,
982 `LONG_PROP_1` BIGINT(20) NULL DEFAULT NULL,
983 `LONG_PROP_2` BIGINT(20) NULL DEFAULT NULL,
984 `DEC_PROP_1` DECIMAL(13,4) NULL DEFAULT NULL,
985 `DEC_PROP_2` DECIMAL(13,4) NULL DEFAULT NULL,
986 `BOOL_PROP_1` VARCHAR(1) NULL DEFAULT NULL,
987 `BOOL_PROP_2` VARCHAR(1) NULL DEFAULT NULL,
988 PRIMARY KEY (`SCHED_NAME`, `TRIGGER_NAME`, `TRIGGER_GROUP`),
989 CONSTRAINT `fn_qz_simprop_triggers_ibfk_1`
990 FOREIGN KEY (`SCHED_NAME` , `TRIGGER_NAME` , `TRIGGER_GROUP`)
991 REFERENCES `vid_openecomp_epsdk`.`fn_qz_triggers` (`SCHED_NAME` , `TRIGGER_NAME` , `TRIGGER_GROUP`))
992ENGINE = InnoDB
993DEFAULT CHARACTER SET = utf8;
994
995-- ----------------------------------------------------------------------------
996-- Table vid_openecomp_epsdk.fn_qz_triggers
997-- ----------------------------------------------------------------------------
998CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_qz_triggers` (
999 `SCHED_NAME` VARCHAR(120) NOT NULL,
1000 `TRIGGER_NAME` VARCHAR(200) NOT NULL,
1001 `TRIGGER_GROUP` VARCHAR(200) NOT NULL,
1002 `JOB_NAME` VARCHAR(200) NOT NULL,
1003 `JOB_GROUP` VARCHAR(200) NOT NULL,
1004 `DESCRIPTION` VARCHAR(250) NULL DEFAULT NULL,
1005 `NEXT_FIRE_TIME` BIGINT(13) NULL DEFAULT NULL,
1006 `PREV_FIRE_TIME` BIGINT(13) NULL DEFAULT NULL,
1007 `PRIORITY` INT(11) NULL DEFAULT NULL,
1008 `TRIGGER_STATE` VARCHAR(16) NOT NULL,
1009 `TRIGGER_TYPE` VARCHAR(8) NOT NULL,
1010 `START_TIME` BIGINT(13) NOT NULL,
1011 `END_TIME` BIGINT(13) NULL DEFAULT NULL,
1012 `CALENDAR_NAME` VARCHAR(200) NULL DEFAULT NULL,
1013 `MISFIRE_INSTR` SMALLINT(2) NULL DEFAULT NULL,
1014 `JOB_DATA` BLOB NULL DEFAULT NULL,
1015 PRIMARY KEY (`SCHED_NAME`, `TRIGGER_NAME`, `TRIGGER_GROUP`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001016 INDEX `IDX_FN_QZ_T_J` (`SCHED_NAME` ASC, `JOB_NAME` ASC, `JOB_GROUP` ASC),
1017 INDEX `IDX_FN_QZ_T_JG` (`SCHED_NAME` ASC, `JOB_GROUP` ASC),
1018 INDEX `IDX_FN_QZ_T_C` (`SCHED_NAME` ASC, `CALENDAR_NAME` ASC),
1019 INDEX `IDX_FN_QZ_T_G` (`SCHED_NAME` ASC, `TRIGGER_GROUP` ASC),
1020 INDEX `IDX_FN_QZ_T_STATE` (`SCHED_NAME` ASC, `TRIGGER_STATE` ASC),
1021 INDEX `IDX_FN_QZ_T_N_STATE` (`SCHED_NAME` ASC, `TRIGGER_NAME` ASC, `TRIGGER_GROUP` ASC, `TRIGGER_STATE` ASC),
1022 INDEX `IDX_FN_QZ_T_N_G_STATE` (`SCHED_NAME` ASC, `TRIGGER_GROUP` ASC, `TRIGGER_STATE` ASC),
1023 INDEX `IDX_FN_QZ_T_NEXT_FIRE_TIME` (`SCHED_NAME` ASC, `NEXT_FIRE_TIME` ASC),
1024 INDEX `IDX_FN_QZ_T_NFT_ST` (`SCHED_NAME` ASC, `TRIGGER_STATE` ASC, `NEXT_FIRE_TIME` ASC),
1025 INDEX `IDX_FN_QZ_T_NFT_MISFIRE` (`SCHED_NAME` ASC, `MISFIRE_INSTR` ASC, `NEXT_FIRE_TIME` ASC),
1026 INDEX `IDX_FN_QZ_T_NFT_ST_MISFIRE` (`SCHED_NAME` ASC, `MISFIRE_INSTR` ASC, `NEXT_FIRE_TIME` ASC, `TRIGGER_STATE` ASC),
1027 INDEX `IDX_FN_QZ_T_NFT_ST_MISFIRE_GRP` (`SCHED_NAME` ASC, `MISFIRE_INSTR` ASC, `NEXT_FIRE_TIME` ASC, `TRIGGER_GROUP` ASC, `TRIGGER_STATE` ASC),
jimmydot3982f4f2017-05-07 14:58:24 -04001028 CONSTRAINT `fn_qz_triggers_ibfk_1`
1029 FOREIGN KEY (`SCHED_NAME` , `JOB_NAME` , `JOB_GROUP`)
1030 REFERENCES `vid_openecomp_epsdk`.`fn_qz_job_details` (`SCHED_NAME` , `JOB_NAME` , `JOB_GROUP`))
1031ENGINE = InnoDB
1032DEFAULT CHARACTER SET = utf8;
1033
1034-- ----------------------------------------------------------------------------
1035-- Table vid_openecomp_epsdk.fn_restricted_url
1036-- ----------------------------------------------------------------------------
1037CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_restricted_url` (
1038 `RESTRICTED_URL` VARCHAR(250) NOT NULL,
1039 `FUNCTION_CD` VARCHAR(30) NOT NULL,
1040 PRIMARY KEY (`RESTRICTED_URL`, `FUNCTION_CD`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001041 INDEX `FK_RESTRICTED_URL_FUNCTION_CD` (`FUNCTION_CD` ASC),
1042 CONSTRAINT `FK_RESTRICTED_URL_FUNCTION_CD`
jimmydot3982f4f2017-05-07 14:58:24 -04001043 FOREIGN KEY (`FUNCTION_CD`)
1044 REFERENCES `vid_openecomp_epsdk`.`fn_function` (`FUNCTION_CD`))
1045ENGINE = InnoDB
1046DEFAULT CHARACTER SET = utf8;
1047
1048-- ----------------------------------------------------------------------------
1049-- Table vid_openecomp_epsdk.fn_role
1050-- ----------------------------------------------------------------------------
1051CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_role` (
1052 `ROLE_ID` INT(11) NOT NULL AUTO_INCREMENT,
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001053 `ROLE_NAME` VARCHAR(255) NOT NULL,
jimmydot3982f4f2017-05-07 14:58:24 -04001054 `ACTIVE_YN` VARCHAR(1) NOT NULL DEFAULT 'Y',
1055 `PRIORITY` DECIMAL(4,0) NULL DEFAULT NULL,
1056 PRIMARY KEY (`ROLE_ID`))
1057ENGINE = InnoDB
1058AUTO_INCREMENT = 17
1059DEFAULT CHARACTER SET = utf8;
1060
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001061ALTER TABLE `vid_openecomp_epsdk`.`fn_role` MODIFY `ROLE_NAME` VARCHAR (255);
1062
1063
jimmydot3982f4f2017-05-07 14:58:24 -04001064-- ----------------------------------------------------------------------------
1065-- Table vid_openecomp_epsdk.fn_role_composite
1066-- ----------------------------------------------------------------------------
1067CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_role_composite` (
1068 `PARENT_ROLE_ID` INT(11) NOT NULL,
1069 `CHILD_ROLE_ID` INT(11) NOT NULL,
1070 PRIMARY KEY (`PARENT_ROLE_ID`, `CHILD_ROLE_ID`),
1071 INDEX `FK_FN_ROLE_COMPOSITE_CHILD` (`CHILD_ROLE_ID` ASC),
1072 CONSTRAINT `FK_FN_ROLE_COMPOSITE_CHILD`
1073 FOREIGN KEY (`CHILD_ROLE_ID`)
1074 REFERENCES `vid_openecomp_epsdk`.`fn_role` (`ROLE_ID`),
1075 CONSTRAINT `FK_FN_ROLE_COMPOSITE_PARENT`
1076 FOREIGN KEY (`PARENT_ROLE_ID`)
1077 REFERENCES `vid_openecomp_epsdk`.`fn_role` (`ROLE_ID`))
1078ENGINE = InnoDB
1079DEFAULT CHARACTER SET = utf8;
1080
1081-- ----------------------------------------------------------------------------
1082-- Table vid_openecomp_epsdk.fn_role_function
1083-- ----------------------------------------------------------------------------
1084CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_role_function` (
1085 `ROLE_ID` INT(11) NOT NULL,
1086 `FUNCTION_CD` VARCHAR(30) NOT NULL,
1087 PRIMARY KEY (`ROLE_ID`, `FUNCTION_CD`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001088 INDEX `FN_ROLE_FUNCTION_FUNCTION_CD` (`FUNCTION_CD` ASC),
1089 INDEX `FN_ROLE_FUNCTION_ROLE_ID` (`ROLE_ID` ASC),
jimmydot3982f4f2017-05-07 14:58:24 -04001090 CONSTRAINT `FK_FN_ROLE__REF_198_FN_ROLE`
1091 FOREIGN KEY (`ROLE_ID`)
1092 REFERENCES `vid_openecomp_epsdk`.`fn_role` (`ROLE_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001093 CONSTRAINT `FK_FN_ROLE__REF_201_FN_FUNCT`
jimmydot3982f4f2017-05-07 14:58:24 -04001094 FOREIGN KEY (`FUNCTION_CD`)
1095 REFERENCES `vid_openecomp_epsdk`.`fn_function` (`FUNCTION_CD`))
1096ENGINE = InnoDB
1097DEFAULT CHARACTER SET = utf8;
1098
1099-- ----------------------------------------------------------------------------
1100-- Table vid_openecomp_epsdk.fn_schedule_workflows
1101-- ----------------------------------------------------------------------------
1102CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_schedule_workflows` (
1103 `id_schedule_workflows` BIGINT(25) NOT NULL AUTO_INCREMENT,
1104 `workflow_server_url` VARCHAR(45) NULL DEFAULT NULL,
1105 `workflow_key` VARCHAR(45) NOT NULL,
1106 `workflow_arguments` VARCHAR(45) NULL DEFAULT NULL,
1107 `startDateTimeCron` VARCHAR(45) NULL DEFAULT NULL,
1108 `endDateTime` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
1109 `start_date_time` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
1110 `recurrence` VARCHAR(45) NULL DEFAULT NULL,
1111 PRIMARY KEY (`id_schedule_workflows`))
1112ENGINE = InnoDB
1113DEFAULT CHARACTER SET = utf8;
1114
1115-- ----------------------------------------------------------------------------
1116-- Table vid_openecomp_epsdk.fn_tab
1117-- ----------------------------------------------------------------------------
1118CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_tab` (
1119 `TAB_CD` VARCHAR(30) NOT NULL,
1120 `TAB_NAME` VARCHAR(50) NOT NULL,
1121 `TAB_DESCR` VARCHAR(100) NULL DEFAULT NULL,
1122 `ACTION` VARCHAR(100) NOT NULL,
1123 `FUNCTION_CD` VARCHAR(30) NOT NULL,
1124 `ACTIVE_YN` CHAR(1) NOT NULL,
1125 `SORT_ORDER` DECIMAL(11,0) NOT NULL,
1126 `PARENT_TAB_CD` VARCHAR(30) NULL DEFAULT NULL,
1127 `TAB_SET_CD` VARCHAR(30) NULL DEFAULT NULL,
1128 PRIMARY KEY (`TAB_CD`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001129 INDEX `FK_FN_TAB_FUNCTION_CD` (`FUNCTION_CD` ASC),
1130 INDEX `FK_FN_TAB_SET_CD` (`TAB_SET_CD` ASC),
1131 CONSTRAINT `FK_FN_TAB_FUNCTION_CD`
jimmydot3982f4f2017-05-07 14:58:24 -04001132 FOREIGN KEY (`FUNCTION_CD`)
1133 REFERENCES `vid_openecomp_epsdk`.`fn_function` (`FUNCTION_CD`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001134 CONSTRAINT `FK_FN_TAB_SET_CD`
jimmydot3982f4f2017-05-07 14:58:24 -04001135 FOREIGN KEY (`TAB_SET_CD`)
1136 REFERENCES `vid_openecomp_epsdk`.`fn_lu_tab_set` (`TAB_SET_CD`))
1137ENGINE = InnoDB
1138DEFAULT CHARACTER SET = utf8;
1139
1140-- ----------------------------------------------------------------------------
1141-- Table vid_openecomp_epsdk.fn_tab_selected
1142-- ----------------------------------------------------------------------------
1143CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_tab_selected` (
1144 `SELECTED_TAB_CD` VARCHAR(30) NOT NULL,
1145 `TAB_URI` VARCHAR(40) NOT NULL,
1146 PRIMARY KEY (`SELECTED_TAB_CD`, `TAB_URI`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001147 CONSTRAINT `FK_FN_TAB_SELECTED_TAB_CD`
jimmydot3982f4f2017-05-07 14:58:24 -04001148 FOREIGN KEY (`SELECTED_TAB_CD`)
1149 REFERENCES `vid_openecomp_epsdk`.`fn_tab` (`TAB_CD`))
1150ENGINE = InnoDB
1151DEFAULT CHARACTER SET = utf8;
1152
1153-- ----------------------------------------------------------------------------
1154-- Table vid_openecomp_epsdk.fn_user
1155-- ----------------------------------------------------------------------------
1156CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_user` (
1157 `USER_ID` INT(11) NOT NULL AUTO_INCREMENT,
1158 `ORG_ID` INT(11) NULL DEFAULT NULL,
1159 `MANAGER_ID` INT(11) NULL DEFAULT NULL,
1160 `FIRST_NAME` VARCHAR(50) NULL DEFAULT NULL,
1161 `MIDDLE_NAME` VARCHAR(50) NULL DEFAULT NULL,
1162 `LAST_NAME` VARCHAR(50) NULL DEFAULT NULL,
1163 `PHONE` VARCHAR(25) NULL DEFAULT NULL,
1164 `FAX` VARCHAR(25) NULL DEFAULT NULL,
1165 `CELLULAR` VARCHAR(25) NULL DEFAULT NULL,
1166 `EMAIL` VARCHAR(50) NULL DEFAULT NULL,
1167 `ADDRESS_ID` DECIMAL(11,0) NULL DEFAULT NULL,
1168 `ALERT_METHOD_CD` VARCHAR(10) NULL DEFAULT NULL,
1169 `HRID` VARCHAR(20) NULL DEFAULT NULL,
1170 `ORG_USER_ID` VARCHAR(20) NULL DEFAULT NULL,
1171 `ORG_CODE` VARCHAR(30) NULL DEFAULT NULL,
1172 `LOGIN_ID` VARCHAR(25) NULL DEFAULT NULL,
1173 `LOGIN_PWD` VARCHAR(25) NULL DEFAULT NULL,
1174 `LAST_LOGIN_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
1175 `ACTIVE_YN` VARCHAR(1) NOT NULL DEFAULT 'Y',
1176 `CREATED_ID` INT(11) NULL DEFAULT NULL,
1177 `CREATED_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
1178 `MODIFIED_ID` INT(11) NULL DEFAULT NULL,
1179 `MODIFIED_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
1180 `IS_INTERNAL_YN` CHAR(1) NOT NULL DEFAULT 'N',
1181 `ADDRESS_LINE_1` VARCHAR(100) NULL DEFAULT NULL,
1182 `ADDRESS_LINE_2` VARCHAR(100) NULL DEFAULT NULL,
1183 `CITY` VARCHAR(50) NULL DEFAULT NULL,
1184 `STATE_CD` VARCHAR(3) NULL DEFAULT NULL,
1185 `ZIP_CODE` VARCHAR(11) NULL DEFAULT NULL,
1186 `COUNTRY_CD` VARCHAR(3) NULL DEFAULT NULL,
1187 `LOCATION_CLLI` VARCHAR(8) NULL DEFAULT NULL,
1188 `ORG_MANAGER_USERID` VARCHAR(20) NULL DEFAULT NULL,
1189 `COMPANY` VARCHAR(100) NULL DEFAULT NULL,
1190 `DEPARTMENT_NAME` VARCHAR(100) NULL DEFAULT NULL,
1191 `JOB_TITLE` VARCHAR(100) NULL DEFAULT NULL,
1192 `TIMEZONE` INT(11) NULL DEFAULT NULL,
1193 `DEPARTMENT` VARCHAR(25) NULL DEFAULT NULL,
1194 `BUSINESS_UNIT` VARCHAR(25) NULL DEFAULT NULL,
1195 `BUSINESS_UNIT_NAME` VARCHAR(100) NULL DEFAULT NULL,
1196 `COST_CENTER` VARCHAR(25) NULL DEFAULT NULL,
1197 `FIN_LOC_CODE` VARCHAR(10) NULL DEFAULT NULL,
1198 `SILO_STATUS` VARCHAR(10) NULL DEFAULT NULL,
1199 PRIMARY KEY (`USER_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001200 UNIQUE INDEX `FN_USER_HRID` (`HRID` ASC),
1201 UNIQUE INDEX `FN_USER_LOGIN_ID` (`LOGIN_ID` ASC),
1202 INDEX `FN_USER_ADDRESS_ID` (`ADDRESS_ID` ASC),
1203 INDEX `FN_USER_ALERT_METHOD_CD` (`ALERT_METHOD_CD` ASC),
1204 INDEX `FN_USER_ORG_ID` (`ORG_ID` ASC),
1205 INDEX `FK_FN_USER_REF_197_FN_USER` (`MANAGER_ID` ASC),
1206 INDEX `FK_FN_USER_REF_198_FN_USER` (`CREATED_ID` ASC),
1207 INDEX `FK_FN_USER_REF_199_FN_USER` (`MODIFIED_ID` ASC),
1208 INDEX `FK_TIMEZONE` (`TIMEZONE` ASC),
1209 CONSTRAINT `FK_FN_USER_REF_110_FN_ORG`
jimmydot3982f4f2017-05-07 14:58:24 -04001210 FOREIGN KEY (`ORG_ID`)
1211 REFERENCES `vid_openecomp_epsdk`.`fn_org` (`ORG_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001212 CONSTRAINT `FK_FN_USER_REF_123_FN_LU_AL`
jimmydot3982f4f2017-05-07 14:58:24 -04001213 FOREIGN KEY (`ALERT_METHOD_CD`)
1214 REFERENCES `vid_openecomp_epsdk`.`fn_lu_alert_method` (`ALERT_METHOD_CD`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001215 CONSTRAINT `FK_FN_USER_REF_197_FN_USER`
jimmydot3982f4f2017-05-07 14:58:24 -04001216 FOREIGN KEY (`MANAGER_ID`)
1217 REFERENCES `vid_openecomp_epsdk`.`fn_user` (`USER_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001218 CONSTRAINT `FK_FN_USER_REF_198_FN_USER`
jimmydot3982f4f2017-05-07 14:58:24 -04001219 FOREIGN KEY (`CREATED_ID`)
1220 REFERENCES `vid_openecomp_epsdk`.`fn_user` (`USER_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001221 CONSTRAINT `FK_FN_USER_REF_199_FN_USER`
jimmydot3982f4f2017-05-07 14:58:24 -04001222 FOREIGN KEY (`MODIFIED_ID`)
1223 REFERENCES `vid_openecomp_epsdk`.`fn_user` (`USER_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001224 CONSTRAINT `FK_TIMEZONE`
jimmydot3982f4f2017-05-07 14:58:24 -04001225 FOREIGN KEY (`TIMEZONE`)
1226 REFERENCES `vid_openecomp_epsdk`.`fn_lu_timezone` (`TIMEZONE_ID`))
1227ENGINE = InnoDB
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001228AUTO_INCREMENT = 3
jimmydot3982f4f2017-05-07 14:58:24 -04001229DEFAULT CHARACTER SET = utf8;
1230
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001231
jimmydot3982f4f2017-05-07 14:58:24 -04001232-- ----------------------------------------------------------------------------
1233-- Table vid_openecomp_epsdk.fn_user_pseudo_role
1234-- ----------------------------------------------------------------------------
1235CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_user_pseudo_role` (
1236 `PSEUDO_ROLE_ID` INT(11) NOT NULL,
1237 `USER_ID` INT(11) NOT NULL,
1238 PRIMARY KEY (`PSEUDO_ROLE_ID`, `USER_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001239 INDEX `FK_PSEUDO_ROLE_USER_ID` (`USER_ID` ASC),
1240 CONSTRAINT `FK_PSEUDO_ROLE_PSEUDO_ROLE_ID`
jimmydot3982f4f2017-05-07 14:58:24 -04001241 FOREIGN KEY (`PSEUDO_ROLE_ID`)
1242 REFERENCES `vid_openecomp_epsdk`.`fn_role` (`ROLE_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001243 CONSTRAINT `FK_PSEUDO_ROLE_USER_ID`
jimmydot3982f4f2017-05-07 14:58:24 -04001244 FOREIGN KEY (`USER_ID`)
1245 REFERENCES `vid_openecomp_epsdk`.`fn_user` (`USER_ID`))
1246ENGINE = InnoDB
1247DEFAULT CHARACTER SET = utf8;
1248
1249-- ----------------------------------------------------------------------------
1250-- Table vid_openecomp_epsdk.fn_user_role
1251-- ----------------------------------------------------------------------------
1252CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_user_role` (
1253 `USER_ID` INT(10) NOT NULL,
1254 `ROLE_ID` INT(10) NOT NULL,
1255 `PRIORITY` DECIMAL(4,0) NULL DEFAULT NULL,
1256 `APP_ID` INT(11) NOT NULL DEFAULT '1',
1257 PRIMARY KEY (`USER_ID`, `ROLE_ID`, `APP_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001258 INDEX `FN_USER_ROLE_ROLE_ID` (`ROLE_ID` ASC),
1259 INDEX `FN_USER_ROLE_USER_ID` (`USER_ID` ASC),
1260 INDEX `FK_FN_USER__REF_178_FN_APP_idx` (`APP_ID` ASC),
jimmydot3982f4f2017-05-07 14:58:24 -04001261 CONSTRAINT `FK_FN_USER__REF_172_FN_USER`
1262 FOREIGN KEY (`USER_ID`)
1263 REFERENCES `vid_openecomp_epsdk`.`fn_user` (`USER_ID`),
1264 CONSTRAINT `FK_FN_USER__REF_175_FN_ROLE`
1265 FOREIGN KEY (`ROLE_ID`)
1266 REFERENCES `vid_openecomp_epsdk`.`fn_role` (`ROLE_ID`),
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001267 CONSTRAINT `FK_FN_USER__REF_178_FN_APP`
jimmydot3982f4f2017-05-07 14:58:24 -04001268 FOREIGN KEY (`APP_ID`)
1269 REFERENCES `vid_openecomp_epsdk`.`fn_app` (`APP_ID`))
1270ENGINE = InnoDB
1271DEFAULT CHARACTER SET = utf8;
1272
1273-- ----------------------------------------------------------------------------
1274-- Table vid_openecomp_epsdk.fn_workflow
1275-- ----------------------------------------------------------------------------
1276CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_workflow` (
1277 `id` MEDIUMINT(9) NOT NULL AUTO_INCREMENT,
1278 `name` VARCHAR(20) NOT NULL,
1279 `description` VARCHAR(500) NULL DEFAULT NULL,
1280 `run_link` VARCHAR(300) NULL DEFAULT NULL,
1281 `suspend_link` VARCHAR(300) NULL DEFAULT NULL,
1282 `modified_link` VARCHAR(300) NULL DEFAULT NULL,
1283 `active_yn` VARCHAR(300) NULL DEFAULT NULL,
1284 `created` VARCHAR(300) NULL DEFAULT NULL,
1285 `created_by` INT(11) NULL DEFAULT NULL,
1286 `modified` VARCHAR(300) NULL DEFAULT NULL,
1287 `modified_by` INT(11) NULL DEFAULT NULL,
1288 `workflow_key` VARCHAR(50) NULL DEFAULT NULL,
1289 PRIMARY KEY (`id`),
1290 UNIQUE INDEX `name` (`name` ASC))
1291ENGINE = InnoDB
1292DEFAULT CHARACTER SET = utf8;
1293
1294-- ----------------------------------------------------------------------------
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001295-- Table vid_openecomp_epsdk.fn_xmltype
jimmydot3982f4f2017-05-07 14:58:24 -04001296-- ----------------------------------------------------------------------------
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001297CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`fn_xmltype` (
1298 `ID` DECIMAL(10,0) NOT NULL,
1299 `XML_DOCUMENT` TEXT NULL DEFAULT NULL,
1300 UNIQUE INDEX `FN_XMLTYPE_ID` (`ID` ASC))
jimmydot3982f4f2017-05-07 14:58:24 -04001301ENGINE = InnoDB
1302DEFAULT CHARACTER SET = utf8;
1303
1304-- ----------------------------------------------------------------------------
1305-- Table vid_openecomp_epsdk.schema_info
1306-- ----------------------------------------------------------------------------
1307CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`schema_info` (
1308 `SCHEMA_ID` VARCHAR(25) NOT NULL,
1309 `SCHEMA_DESC` VARCHAR(75) NOT NULL,
1310 `DATASOURCE_TYPE` VARCHAR(100) NULL DEFAULT NULL,
1311 `CONNECTION_URL` VARCHAR(200) NOT NULL,
1312 `USER_NAME` VARCHAR(45) NOT NULL,
1313 `PASSWORD` VARCHAR(45) NULL DEFAULT NULL,
1314 `DRIVER_CLASS` VARCHAR(100) NOT NULL,
1315 `MIN_POOL_SIZE` INT(11) NOT NULL,
1316 `MAX_POOL_SIZE` INT(11) NOT NULL,
1317 `IDLE_CONNECTION_TEST_PERIOD` INT(11) NOT NULL)
1318ENGINE = InnoDB
1319DEFAULT CHARACTER SET = utf8;
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001320-- ----------------------------------------------------------------------------
1321-- Table vid_openecomp_epsdk.vid_vnf
1322-- ----------------------------------------------------------------------------
1323
1324CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`vid_vnf` (
1325 `VNF_DB_ID` int(11) NOT NULL AUTO_INCREMENT,
1326 `VNF_APP_UUID` varchar(255) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL,
1327 `VNF_APP_INVARIANT_UUID` varchar(255) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL,
1328 `CREATED_DATE` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
1329 `MODIFIED_DATE` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
1330 PRIMARY KEY (`VNF_DB_ID`),
1331 UNIQUE KEY `vid_vnf_VNF_ID_uindex` (`VNF_APP_UUID`,`VNF_APP_INVARIANT_UUID`)
1332) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8;
1333
1334-- ----------------------------------------------------------------------------
1335-- Table vid_openecomp_epsdk.vid_workflow
1336-- ----------------------------------------------------------------------------
1337
1338CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`vid_workflow` (
1339 `WORKFLOW_DB_ID` int(11) NOT NULL AUTO_INCREMENT,
1340 `WORKFLOW_APP_NAME` varchar(50) COLLATE utf8_bin NOT NULL,
1341 `CREATED_DATE` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
1342 `MODIFIED_DATE` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
1343 PRIMARY KEY (`WORKFLOW_DB_ID`),
1344 UNIQUE KEY `vid_workflow_workflow_uuid_uindex` (`WORKFLOW_APP_NAME`),
1345 UNIQUE KEY `vid_workflow_WORKFLOW_ID_uindex` (`WORKFLOW_DB_ID`)
1346) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
1347
1348-- ----------------------------------------------------------------------------
1349-- Table vid_openecomp_epsdk.vid_vnf_workflow
1350-- ----------------------------------------------------------------------------
1351
1352
1353CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`vid_vnf_workflow` (
1354 `VNF_DB_ID` int(11) NOT NULL,
1355 `WORKFLOW_DB_ID` int(11) NOT NULL,
1356 KEY `vid_vnf_workflow_vid_vnf_VND_ID_fk` (`VNF_DB_ID`),
1357 KEY `vid_vnf_workflow_vid_workflow_WORKFLOW_ID_fk` (`WORKFLOW_DB_ID`),
1358 CONSTRAINT `vid_vnf_workflow_vid_vnf_VND_ID_fk` FOREIGN KEY (`VNF_DB_ID`) REFERENCES `vid_vnf` (`VNF_DB_ID`),
1359 CONSTRAINT `vid_vnf_workflow_vid_workflow_WORKFLOW_ID_fk` FOREIGN KEY (`WORKFLOW_DB_ID`) REFERENCES `vid_openecomp_epsdk`.`vid_workflow` (`WORKFLOW_DB_ID`)
1360) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
1361
1362
1363-- ----------------------------------------------------------------------------
1364-- Table vid_openecomp_epsdk.vid_category_parameter
1365-- ----------------------------------------------------------------------------
1366
1367
1368CREATE TABLE IF NOT EXISTS `vid_category_parameter` (
1369 `CATEGORY_ID` INT(11) NOT NULL AUTO_INCREMENT,
1370 `NAME` VARCHAR(255) NULL COLLATE 'utf8_bin',
1371 `ID_SUPPORTED` TINYINT(1) NOT NULL DEFAULT '0',
1372 `CREATED_DATE` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
1373 `MODIFIED_DATE` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
1374 PRIMARY KEY (`CATEGORY_ID`)
1375) COLLATE='utf8_bin' ENGINE=InnoDB AUTO_INCREMENT=5;
1376
1377-------------------------------------------------------------------------------
1378
1379ALTER TABLE `vid_category_parameter`
1380 ADD COLUMN if not exists `FAMILY` ENUM('PARAMETER_STANDARDIZATION','TENANT_ISOLATION') NOT NULL DEFAULT 'PARAMETER_STANDARDIZATION' AFTER `ID_SUPPORTED`;
1381-- ----------------------------------------------------------------------------
1382-- Table vid_openecomp_epsdk.vid_category_parameter
1383-- ----------------------------------------------------------------------------
1384CREATE TABLE IF NOT EXISTS `vid_category_parameter_option` (
1385 `CATEGORY_OPT_DB_ID` INT(11) NOT NULL AUTO_INCREMENT,
1386 `CATEGORY_OPT_APP_ID` VARCHAR(50) NOT NULL COLLATE 'utf8_bin',
1387 `NAME` VARCHAR(50) NULL COLLATE 'utf8_bin',
1388 `CATEGORY_ID` INT(11) NOT NULL DEFAULT '0',
1389 `CREATED_DATE` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
1390 `MODIFIED_DATE` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
1391 PRIMARY KEY (`CATEGORY_OPT_DB_ID`),
1392 UNIQUE INDEX `APP_ID_CATEGORY_UNIQUE` (`CATEGORY_ID`, `CATEGORY_OPT_APP_ID`),
1393 UNIQUE INDEX `NAME_CATEGORY_UNIQUE` (`CATEGORY_ID`, `NAME`),
1394 CONSTRAINT `FK_OWNING_ENTITY_OPTIONS_TO_OE` FOREIGN KEY (`CATEGORY_ID`) REFERENCES `vid_openecomp_epsdk`.`vid_category_parameter` (`CATEGORY_ID`)
1395) COLLATE='utf8_bin' ENGINE=InnoDB AUTO_INCREMENT=25;
1396
Sonsino, Ofir (os0695)436646f2018-09-05 18:26:30 +03001397CREATE TABLE IF NOT EXISTS `vid_job` (
1398 `JOB_ID` BINARY(16) NOT NULL PRIMARY KEY,
1399 `CREATED_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
1400 `MODIFIED_DATE` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
1401 `JOB_STATUS` VARCHAR(50) NULL COLLATE 'utf8_bin',
1402 `JOB_TYPE` VARCHAR(50) NULL COLLATE 'utf8_bin',
1403 `JOB_DATA` MEDIUMTEXT NULL COLLATE 'utf8_bin',
1404 `PARENT_JOB_ID` BINARY(16) NULL,
1405 `TAKEN_BY` VARCHAR(100) NULL COLLATE 'utf8_bin',
1406 CONSTRAINT `FK_OWNING_VID_JOB_PARENT` FOREIGN KEY (`PARENT_JOB_ID`) REFERENCES `vid_openecomp_epsdk`.`vid_job` (`JOB_ID`)
1407) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
jimmydot3982f4f2017-05-07 14:58:24 -04001408
Sonsino, Ofir (os0695)436646f2018-09-05 18:26:30 +03001409ALTER TABLE `vid_job`
1410 ADD COLUMN if NOT EXISTS `TAKEN_BY` VARCHAR (100) COLLATE 'utf8_bin';
jimmydot3982f4f2017-05-07 14:58:24 -04001411-- ----------------------------------------------------------------------------
1412-- View vid_openecomp_epsdk.v_url_access
1413-- ----------------------------------------------------------------------------
Ofir Sonsino1cfb0872018-01-31 17:19:00 +02001414CREATE OR REPLACE ALGORITHM=UNDEFINED SQL SECURITY DEFINER VIEW `v_url_access` AS select distinct `m`.`ACTION` AS `URL`,`m`.`FUNCTION_CD` AS `FUNCTION_CD` from `fn_menu` `m` where (`m`.`ACTION` is not null) union select distinct `t`.`ACTION` AS `URL`,`t`.`FUNCTION_CD` AS `FUNCTION_CD` from `fn_tab` `t` where (`t`.`ACTION` is not null) union select `r`.`RESTRICTED_URL` AS `URL`,`r`.`FUNCTION_CD` AS `FUNCTION_CD` from `fn_restricted_url` `r`;
Sonsino, Ofir (os0695)7059a9c2018-09-05 16:06:16 +03001415SET FOREIGN_KEY_CHECKS = 1;