Skip to content

Commit 089fc1d

Browse files
committed
Preparing Oracle Tables ...
1 parent 049d3af commit 089fc1d

17 files changed

+449
-103
lines changed
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
CREATE TABLE T4SQL.ENGINE_CONFIG
2+
(
3+
ELEMENT_NAME NVARCHAR2(32) NOT NULL,
4+
NUMBER_VALUE NUMBER,
5+
DATE_VALUE DATE,
6+
STRING_VALUE NVARCHAR2(256),
7+
DESCRIPTION_ NVARCHAR2(256),
8+
9+
CONSTRAINT PK_ENGINE_CONFIG PRIMARY KEY (ELEMENT_NAME),
10+
CONSTRAINT CK_ENGINE_CONFIG_VALUE CHECK (NUMBER_VALUE IS NOT NULL OR DATE_VALUE IS NOT NULL OR STRING_VALUE IS NOT NULL)
11+
)
12+
ORGANIZATION INDEX
13+
STORAGE (INITIAL 16K NEXT 8K BUFFER_POOL KEEP);
14+
15+
----------------------------------------------------------------------------------------------------
16+
--
17+
-- Copyright 2013 Abel Cheng
18+
-- This source code is subject to terms and conditions of the Apache License, Version 2.0.
19+
-- See http://www.apache.org/licenses/LICENSE-2.0.
20+
-- All other rights reserved.
21+
-- You must not remove this notice, or any other, from this software.
22+
--
23+
-- Original Author: Abel Cheng <[email protected]>
24+
-- Created Date: ‎October ‎12, ‎2013, ‏‎12:21:08 AM
25+
-- Primary Host: http://t4sql.codeplex.com
26+
-- Change Log:
27+
-- Author Date Comment
28+
--
29+
--
30+
--
31+
--
32+
-- (Keep code clean rather than complicated code plus long comments.)
33+
--
34+
----------------------------------------------------------------------------------------------------
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
CREATE TABLE T4SQL.ENGINE_SERVER
2+
(
3+
SERVER_NAME NVARCHAR2(32) NOT NULL,
4+
SERVICE_BEAT TIMESTAMP(3) DEFAULT SYSTIMESTAMP NOT NULL,
5+
IS_PRIMARY CHAR(1) DEFAULT 'Y' NOT NULL,
6+
SERVICE_ACCOUNT NVARCHAR2(32),
7+
CONSTRAINT PK_ENGINE_SERVER PRIMARY KEY (SERVER_NAME)
8+
)
9+
ORGANIZATION INDEX
10+
STORAGE (INITIAL 16K NEXT 8K);
11+
12+
----------------------------------------------------------------------------------------------------
13+
--
14+
-- Copyright 2012 Abel Cheng
15+
-- This source code is subject to terms and conditions of the Apache License, Version 2.0.
16+
-- See http://www.apache.org/licenses/LICENSE-2.0.
17+
-- All other rights reserved.
18+
-- You must not remove this notice, or any other, from this software.
19+
--
20+
-- Original Author: Abel Cheng <[email protected]>
21+
-- Created Date: ‎October ‎12, ‎2013, ‏‎12:42:26 AM
22+
-- Primary Host: http://t4sql.codeplex.com
23+
-- Change Log:
24+
-- Author Date Comment
25+
--
26+
--
27+
--
28+
--
29+
-- (Keep clean code rather than complicated code plus long comments.)
30+
--
31+
----------------------------------------------------------------------------------------------------
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
CREATE TABLE T4SQL.EVENT_LOG
2+
(
3+
LOG_TIME TIMESTAMP(3) NOT NULL,
4+
LOG_TYPE NVARCHAR2(16),
5+
REFERENCE_ NVARCHAR2(256),
6+
MESSAGE_ VARCHAR2(4000)
7+
)
8+
STORAGE (INITIAL 1M NEXT 1M);
9+
10+
----------------------------------------------------------------------------------------------------
11+
--
12+
-- Copyright 2013 Abel Cheng
13+
-- This source code is subject to terms and conditions of the Apache License, Version 2.0.
14+
-- See http://www.apache.org/licenses/LICENSE-2.0.
15+
-- All other rights reserved.
16+
-- You must not remove this notice, or any other, from this software.
17+
--
18+
-- Original Author: Abel Cheng <[email protected]>
19+
-- Created Date: ‎October ‎12, ‎2013, ‏‎11:30:46 PM
20+
-- Primary Host: http://t4sql.codeplex.com
21+
-- Change Log:
22+
-- Author Date Comment
23+
--
24+
--
25+
--
26+
--
27+
-- (Keep code clean)
28+
--
29+
----------------------------------------------------------------------------------------------------
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
CREATE TABLE T4SQL.TEMPLATE_CLASS
2+
(
3+
FULL_NAME VARCHAR2(128) NOT NULL,
4+
MODULE NVARCHAR2(128) NOT NULL,
5+
ASSEMBLY_STRING VARCHAR2(256) NOT NULL,
6+
CREATED_TIME DATE NOT NULL,
7+
START_TIME DATE NOT NULL,
8+
IS_ACTIVE CHAR(1) NOT NULL,
9+
CLASS_DESCRIPTION NVARCHAR2(1024),
10+
11+
CONSTRAINT PK_TEMPLATE_CLASS PRIMARY KEY (FULL_NAME)
12+
)
13+
ORGANIZATION INDEX
14+
STORAGE (INITIAL 128K NEXT 128K);
15+
16+
----------------------------------------------------------------------------------------------------
17+
--
18+
-- Copyright 2013 Abel Cheng
19+
-- This source code is subject to terms and conditions of the Apache License, Version 2.0.
20+
-- See http://www.apache.org/licenses/LICENSE-2.0.
21+
-- All other rights reserved.
22+
-- You must not remove this notice, or any other, from this software.
23+
--
24+
-- Original Author: Abel Cheng <[email protected]>
25+
-- Created Date: ‎October ‎13, ‎2013, ‏‎12:05:04 AM
26+
-- Primary Host: http://t4sql.codeplex.com
27+
-- Change Log:
28+
-- Author Date Comment
29+
--
30+
--
31+
--
32+
--
33+
-- (Keep code clean)
34+
--
35+
----------------------------------------------------------------------------------------------------
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
CREATE TABLE T4SQL.TEMPLATE_SPEC
2+
(
3+
CLASS_NAME VARCHAR2(128) NOT NULL,
4+
PROPERTY_NAME NVARCHAR2(64) NOT NULL,
5+
DEFAULT_VALUE NVARCHAR2(2000),
6+
LINK_STATE NVARCHAR2(256),
7+
PROPERTY_DESCRIPTION NVARCHAR2(1024),
8+
PROPERTY_ORDER NUMBER(5),
9+
10+
CONSTRAINT PK_TEMPLATE_SPEC PRIMARY KEY (CLASS_NAME, PROPERTY_NAME),
11+
CONSTRAINT FK_TEMPLATE_SPEC_CLASS FOREIGN KEY (CLASS_NAME)
12+
REFERENCES T4SQL.TEMPLATE_CLASS(FULL_NAME)
13+
ON DELETE CASCADE
14+
)
15+
STORAGE (INITIAL 512K NEXT 1M);
16+
17+
CREATE INDEX T4SQL.IX_TEMPLATE_SPEC_ORDER ON T4SQL.TEMPLATE_SPEC (CLASS_NAME, PROPERTY_ORDER);
18+
19+
----------------------------------------------------------------------------------------------------
20+
--
21+
-- Copyright 2013 Abel Cheng
22+
-- This source code is subject to terms and conditions of the Apache License, Version 2.0.
23+
-- See http://www.apache.org/licenses/LICENSE-2.0.
24+
-- All other rights reserved.
25+
-- You must not remove this notice, or any other, from this software.
26+
--
27+
-- Original Author: Abel Cheng <[email protected]>
28+
-- Created Date: ‎‎October ‎13, ‎2013, ‏‎10:38:05 PM
29+
-- Primary Host: http://t4sql.codeplex.com
30+
-- Change Log:
31+
-- Author Date Comment
32+
--
33+
--
34+
--
35+
--
36+
-- (Keep code clean)
37+
--
38+
----------------------------------------------------------------------------------------------------
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
CREATE TABLE T4SQL.WORKSPACE_ENTRY
2+
(
3+
WORKSPACE_ID NUMBER(9) NOT NULL,
4+
WORKITEM_TABLE_NAME VARCHAR2(128) NOT NULL,
5+
PROPERTY_TABLE_NAME VARCHAR2(128) NOT NULL,
6+
WORKSPACE_DESCRIPTION NVARCHAR2(128),
7+
AUTONOMOUS_OWNER NVARCHAR2(64),
8+
9+
CONSTRAINT PK_WORKSPACE_ENTRY PRIMARY KEY (WORKITEM_TABLE_NAME),
10+
CONSTRAINT UK_WORKSPACE_ENTRY_ID UNIQUE (WORKSPACE_ID),
11+
CONSTRAINT UK_WORKSPACE_ENTRY_PT UNIQUE (PROPERTY_TABLE_NAME)
12+
)
13+
ORGANIZATION INDEX
14+
STORAGE (INITIAL 16K NEXT 16K);
15+
16+
----------------------------------------------------------------------------------------------------
17+
--
18+
-- Copyright 2013 Abel Cheng
19+
-- This source code is subject to terms and conditions of the Apache License, Version 2.0.
20+
-- See http://www.apache.org/licenses/LICENSE-2.0.
21+
-- All other rights reserved.
22+
-- You must not remove this notice, or any other, from this software.
23+
--
24+
-- Original Author: Abel Cheng <[email protected]>
25+
-- Created Date: ‎October ‎14, ‎2013, ‏‎12:45:04 AM
26+
-- Primary Host: http://t4sql.codeplex.com
27+
-- Change Log:
28+
-- Author Date Comment
29+
--
30+
--
31+
--
32+
--
33+
-- (Keep code clean)
34+
--
35+
----------------------------------------------------------------------------------------------------
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
CREATE TABLE T4SQL.SEED_WORKITEM
2+
(
3+
WORKITEM_NAME NVARCHAR2(32) NOT NULL,
4+
TEMPLATE_NAME VARCHAR2(128) NOT NULL,
5+
WORKITEM_DESCRIPTION NVARCHAR2(256) NOT NULL,
6+
WORKITEM_USER NVARCHAR2(32),
7+
MODIFIED_TIME TIMESTAMP(3) DEFAULT SYSTIMESTAMP NOT NULL,
8+
COMPILED_TIME TIMESTAMP(3),
9+
COMPILED_ERROR NVARCHAR2(2000),
10+
OBJECT_CODE CLOB,
11+
BUILD_ORDER NUMBER(4),
12+
START_BUILD CHAR(1) DEFAULT 'N' NOT NULL,
13+
14+
CONSTRAINT PK_SEED_WORKITEM PRIMARY KEY (WORKITEM_NAME),
15+
CONSTRAINT FK_SEED_WORKITEM_TEMPLATE_CLS FOREIGN KEY (TEMPLATE_NAME)
16+
REFERENCES T4SQL.TEMPLATE_CLASS(FULL_NAME)
17+
ON DELETE CASCADE
18+
)
19+
STORAGE (INITIAL 16K NEXT 8K);
20+
21+
----------------------------------------------------------------------------------------------------
22+
--
23+
-- Copyright 2013 Abel Cheng
24+
-- This source code is subject to terms and conditions of the Apache License, Version 2.0.
25+
-- See http://www.apache.org/licenses/LICENSE-2.0.
26+
-- All other rights reserved.
27+
-- You must not remove this notice, or any other, from this software.
28+
--
29+
-- Original Author: Abel Cheng <[email protected]>
30+
-- Created Date: ‎October ‎14, ‎2013, ‏‎1:19:39 AM
31+
-- Primary Host: http://t4sql.codeplex.com
32+
-- Change Log:
33+
-- Author Date Comment
34+
--
35+
--
36+
--
37+
--
38+
-- (Keep code clean)
39+
--
40+
----------------------------------------------------------------------------------------------------
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
CREATE TABLE T4SQL.SEED_PROPERTY
2+
(
3+
WORKITEM_NAME NVARCHAR2(32) NOT NULL,
4+
PROPERTY_NAME NVARCHAR2(64) NOT NULL,
5+
STRING_VALUE NVARCHAR2(2000) NOT NULL,
6+
LINK_STATE NVARCHAR2(256),
7+
8+
CONSTRAINT PK_SEED_PROPERTY PRIMARY KEY (WORKITEM_NAME, PROPERTY_NAME),
9+
CONSTRAINT FK_SEED_PROPERTY_WORKITEM FOREIGN KEY (WORKITEM_NAME)
10+
REFERENCES T4SQL.SEED_WORKITEM(WORKITEM_NAME)
11+
ON DELETE CASCADE
12+
)
13+
STORAGE (INITIAL 16K NEXT 64K);
14+
15+
----------------------------------------------------------------------------------------------------
16+
--
17+
-- Copyright 2013 Abel Cheng
18+
-- This source code is subject to terms and conditions of the Apache License, Version 2.0.
19+
-- See http://www.apache.org/licenses/LICENSE-2.0.
20+
-- All other rights reserved.
21+
-- You must not remove this notice, or any other, from this software.
22+
--
23+
-- Original Author: Abel Cheng <[email protected]>
24+
-- Created Date: ‎‎October ‎14, ‎2013, ‏‎10:18:56 PM
25+
-- Primary Host: http://t4sql.codeplex.com
26+
-- Change Log:
27+
-- Author Date Comment
28+
--
29+
--
30+
--
31+
--
32+
-- (Keep code clean)
33+
--
34+
----------------------------------------------------------------------------------------------------
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
CREATE TABLE T4SQL.UTL_ORDINAL_NUMBER
2+
(
3+
ORDINAL_NUMBER NUMBER(5) NOT NULL,
4+
5+
CONSTRAINT PK_UTL_ORDINAL_NUMBER PRIMARY KEY (ORDINAL_NUMBER)
6+
)
7+
ORGANIZATION INDEX
8+
STORAGE (INITIAL 256K NEXT 128K);
9+
10+
----------------------------------------------------------------------------------------------------
11+
--
12+
-- Copyright 2013 Abel Cheng
13+
-- This source code is subject to terms and conditions of the Apache License, Version 2.0.
14+
-- See http://www.apache.org/licenses/LICENSE-2.0.
15+
-- All other rights reserved.
16+
-- You must not remove this notice, or any other, from this software.
17+
--
18+
-- Original Author: Abel Cheng <[email protected]>
19+
-- Created Date: ‎‎October ‎14, ‎2013, ‏‎10:30:47 PM
20+
-- Primary Host: http://t4sql.codeplex.com
21+
-- Change Log:
22+
-- Author Date Comment
23+
--
24+
--
25+
--
26+
--
27+
-- (Keep code clean)
28+
--
29+
----------------------------------------------------------------------------------------------------
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
CREATE SEQUENCE T4SQL.SEQ_WORKSPACE_ID
2+
START WITH 1
3+
INCREMENT BY 1
4+
MINVALUE 1
5+
NOMAXVALUE
6+
NOCYCLE
7+
;
8+
9+
----------------------------------------------------------------------------------------------------
10+
--
11+
-- Copyright 2013 Abel Cheng
12+
-- This source code is subject to terms and conditions of the Apache License, Version 2.0.
13+
-- See http://www.apache.org/licenses/LICENSE-2.0.
14+
-- All other rights reserved.
15+
-- You must not remove this notice, or any other, from this software.
16+
--
17+
-- Original Author: Abel Cheng <[email protected]>
18+
-- Created Date: October ?13, ?2013, ??11:49:27 PM
19+
-- Primary Host: http://t4sql.codeplex.com
20+
-- Change Log:
21+
-- Author Date Comment
22+
--
23+
--
24+
--
25+
--
26+
-- (Keep code clean)
27+
--
28+
----------------------------------------------------------------------------------------------------

0 commit comments

Comments
 (0)