リビジョン 90
資材管理、請求管理のテーブル作成
branches/ddl/create_table_mysql.sql | ||
---|---|---|
1 |
CREATE TABLE ACTIONSCHEDULEDATA |
|
2 |
( TARGETDATE DATE NOT NULL, |
|
3 |
PERSONCODE NUMERIC(8,0) NOT NULL, |
|
4 |
ACTIONSCHEDULE VARCHAR(30), |
|
5 |
TARGETYEAR NUMERIC(4,0) NOT NULL, |
|
6 |
TARGETMONTH NUMERIC(2,0) NOT NULL, |
|
7 |
TARGETDAY NUMERIC(2,0) NOT NULL, |
|
8 |
ENTRYDATE DATETIME NOT NULL, |
|
9 |
UPDATEDATE DATETIME NOT NULL, |
|
10 |
PRIMARY KEY(TARGETDATE, PERSONCODE) |
|
11 |
); |
|
1 |
-- Project Name : noname |
|
2 |
-- Date/Time : 2017/04/28 18:49:40 |
|
3 |
-- Author : yamauchi |
|
4 |
-- RDBMS Type : MySQL |
|
5 |
-- Application : A5:SQL Mk-2 |
|
12 | 6 |
|
13 |
CREATE TABLE APPROVALMASTER |
|
14 |
( APPROVALCODE NUMERIC(3,0) NOT NULL, |
|
15 |
DEPARTMENTCODE NUMERIC(5,0) NOT NULL, |
|
16 |
SEQNO NUMERIC(2,0) NOT NULL, |
|
17 |
DISPLAYORDER NUMERIC(2,0) NOT NULL, |
|
18 |
APPROVALPERSON NUMERIC(8,0) NOT NULL, |
|
19 |
APPROVALAUTHORITY NUMERIC(1,0) NOT NULL, |
|
20 |
ENTRYDATE DATETIME, |
|
21 |
UPDATEDATE DATETIME, |
|
22 |
PRIMARY KEY (APPROVALCODE, DEPARTMENTCODE, SEQNO) |
|
23 |
); |
|
7 |
-- ??s?c????}?X?^ |
|
8 |
drop table if exists bankbusinessdaymaster cascade; |
|
24 | 9 |
|
25 |
CREATE TABLE BUSINESSTYPEMASTER |
|
26 |
( BUSINESSTYPECODE NUMERIC(5,0) NOT NULL, |
|
27 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
28 |
BUSINESSTYPENAME VARCHAR(100) DEFAULT '' NOT NULL, |
|
29 |
ENTRYDATE DATETIME NOT NULL, |
|
30 |
UPDATEDATE DATETIME NOT NULL, |
|
31 |
PRIMARY KEY (BUSINESSTYPECODE) |
|
32 |
); |
|
10 |
create table bankbusinessdaymaster ( |
|
11 |
YEARMONTH decimal(6,0) default '0' not null comment '?N??' |
|
12 |
, BANKBUSINESSDAY decimal(2,0) default '0' not null comment '??s?c???' |
|
13 |
, NOTE varchar(120) comment '???l' |
|
14 |
, DELETEFLG decimal(1,0) comment '???t???O' |
|
15 |
, ENTRYDATE datetime comment '?o?^?N????' |
|
16 |
, UPDATEDATE datetime comment '?X?V?N????' |
|
17 |
, constraint bankbusinessdaymaster_PKC primary key (YEARMONTH,BANKBUSINESSDAY) |
|
18 |
) comment '??s?c????}?X?^' ; |
|
33 | 19 |
|
34 |
CREATE TABLE COMMONCOSTLARGE |
|
35 |
( LARGECODE NUMERIC(5,0) NOT NULL, |
|
36 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
37 |
LARGENAME VARCHAR(50) DEFAULT '' NOT NULL, |
|
38 |
COMMENTTEXT VARCHAR(120), |
|
39 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
40 |
ENTRYDATE DATETIME NOT NULL, |
|
41 |
UPDATEDATE DATETIME NOT NULL, |
|
42 |
PRIMARY KEY (LARGECODE) |
|
43 |
); |
|
20 |
-- ???????f?[?^ |
|
21 |
drop table if exists billingdata cascade; |
|
44 | 22 |
|
45 |
CREATE TABLE COMMONCOSTLINKMS |
|
46 |
( LARGECODE NUMERIC(5,0) NOT NULL, |
|
47 |
MIDDLECODE NUMERIC(5,0) NOT NULL, |
|
48 |
ITEMCODE NUMERIC(5,0) NOT NULL, |
|
49 |
ENTRYDATE DATETIME, |
|
50 |
UPDATEDATE DATETIME, |
|
51 |
PRIMARY KEY (LARGECODE, MIDDLECODE, ITEMCODE) |
|
52 |
); |
|
23 |
create table billingdata ( |
|
24 |
COMPANYCODE decimal(8,0) default '0' not null comment '??????R?[?h' |
|
25 |
, TARGETDATE decimal(6,0) default '0' not null comment '???N??' |
|
26 |
, SEQNO decimal(3,0) default '0' not null comment '?A??' |
|
27 |
, BILLPRICE decimal(10,0) comment '???????z' |
|
28 |
, ENTRYDATE datetime comment '?o?^?N????' |
|
29 |
, UPDATEDATE datetime comment '?X?V?N????' |
|
30 |
, constraint billingdata_PKC primary key (COMPANYCODE,TARGETDATE,SEQNO) |
|
31 |
) comment '???????f?[?^' ; |
|
53 | 32 |
|
54 |
CREATE TABLE COMMONCOSTMIDDLE |
|
55 |
( LARGECODE NUMERIC(5,0) NOT NULL, |
|
56 |
MIDDLECODE NUMERIC(5,0) NOT NULL, |
|
57 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
58 |
MIDDLENAME VARCHAR(50) DEFAULT '' NOT NULL, |
|
59 |
COMMENTTEXT VARCHAR(120), |
|
60 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
61 |
ENTRYDATE DATETIME NOT NULL, |
|
62 |
UPDATEDATE DATETIME NOT NULL, |
|
63 |
PRIMARY KEY (LARGECODE, MIDDLECODE) |
|
64 |
); |
|
33 |
-- ??????????f?[?^ |
|
34 |
drop table if exists billingdatadetail cascade; |
|
65 | 35 |
|
66 |
CREATE TABLE COMMONCOSTMIDDLESEARCHWORD |
|
67 |
( LARGECODE NUMERIC(5,0) NOT NULL, |
|
68 |
MIDDLECODE NUMERIC(5,0) NOT NULL, |
|
69 |
SEQNO NUMERIC(5,0) NOT NULL, |
|
70 |
SEARCHWORD VARCHAR(50) DEFAULT '' NOT NULL, |
|
71 |
ENTRYDATE DATETIME NOT NULL, |
|
72 |
UPDATEDATE DATETIME NOT NULL, |
|
73 |
PRIMARY KEY (LARGECODE, MIDDLECODE, SEQNO) |
|
74 |
); |
|
36 |
create table billingdatadetail ( |
|
37 |
COMPANYCODE decimal(8,0) default '0' not null comment '??????R?[?h' |
|
38 |
, TARGETDATE decimal(6,0) default '0' not null comment '???N??' |
|
39 |
, SEQNO decimal(3,0) default '0' not null comment '?A??' |
|
40 |
, LINECOUNT decimal(3,0) default '0' not null comment '?s???' |
|
41 |
, CONSTRUCTIONCODE decimal(10,0) comment '?H?????' |
|
42 |
, FIELDNAME varchar(120) comment '????' |
|
43 |
, BILLPRICE decimal(10,0) comment '???????z' |
|
44 |
, HIGHWPRICE decimal(10,0) comment '??????' |
|
45 |
, HARDWPRICE decimal(10,0) comment '??????' |
|
46 |
, INDSWASTETAX decimal(10,0) comment '?Y?p??' |
|
47 |
, NOTE varchar(120) comment '???l' |
|
48 |
, ENTRYDATE datetime comment '?o?^?N????' |
|
49 |
, UPDATEDATE datetime comment '?X?V?N????' |
|
50 |
, constraint billingdatadetail_PKC primary key (COMPANYCODE,TARGETDATE,SEQNO,LINECOUNT) |
|
51 |
) comment '??????????f?[?^' ; |
|
75 | 52 |
|
76 |
CREATE TABLE COMPONENTLINKMASTER |
|
77 |
( COMPONENTCODE NUMERIC(5,0) NOT NULL, |
|
78 |
ITEMCODE NUMERIC(5,0) NOT NULL, |
|
79 |
DISPLAYORDER NUMERIC(5,0), |
|
80 |
ENTRYDATE DATETIME NOT NULL, |
|
81 |
UPDATEDATE DATETIME NOT NULL, |
|
82 |
PRIMARY KEY (COMPONENTCODE, ITEMCODE) |
|
83 |
); |
|
53 |
-- ???????x???T?}???[?f?[?^ |
|
54 |
drop table if exists billingpaymentsummary cascade; |
|
84 | 55 |
|
85 |
CREATE TABLE COMPONENTMASTER |
|
86 |
( COMPONENTCODE NUMERIC(5,0) NOT NULL, |
|
87 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
88 |
COMPONENTNAME VARCHAR(120) DEFAULT '' NOT NULL, |
|
89 |
SUBITEMSFLG NUMERIC(1,0), |
|
90 |
DIRECTINPUTFLG NUMERIC(1,0), |
|
91 |
MYEXPENSESFLG NUMERIC(1,0), |
|
92 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
93 |
ENTRYDATE DATETIME NOT NULL, |
|
94 |
UPDATEDATE DATETIME NOT NULL, |
|
95 |
PRIMARY KEY (COMPONENTCODE) |
|
96 |
); |
|
56 |
create table billingpaymentsummary ( |
|
57 |
COMPANYCODE decimal(8,0) default '0' not null comment '??????R?[?h' |
|
58 |
, TARGETDATE decimal(6,0) default '0' not null comment '???N??' |
|
59 |
, CHARGEPAYMENTKIND decimal(1,0) default '0' not null comment '?????x????' |
|
60 |
, PAYDAY date comment '?x????' |
|
61 |
, BILLPRICESTOTAL decimal(10,0) comment '???????z???v' |
|
62 |
, CONSUMPTIONTAXRATE decimal(6,3) comment '??????' |
|
63 |
, CONSUMPTIONTAXPRICE decimal(10,0) comment '?????z' |
|
64 |
, HIGHWPRICESTOTAL decimal(10,0) comment '???????v' |
|
65 |
, HARDWPRICESTOTAL decimal(10,0) comment '???????v' |
|
66 |
, INDSWASTETAXSTOTAL decimal(10,0) comment '?Y?p????v' |
|
67 |
, CNSTRPRICERATE decimal(6,3) comment '???????' |
|
68 |
, CNSTRPRICESTOTAL decimal(10,0) comment '????????v' |
|
69 |
, BILLINGPRICETOTAL decimal(10,0) comment '???????z???v' |
|
70 |
, ENTRYDATE datetime comment '?o?^?N????' |
|
71 |
, UPDATEDATE datetime comment '?X?V?N????' |
|
72 |
, constraint billingpaymentsummary_PKC primary key (COMPANYCODE,TARGETDATE,CHARGEPAYMENTKIND) |
|
73 |
) comment '???????x???T?}???[?f?[?^' ; |
|
97 | 74 |
|
98 |
CREATE TABLE CONSTRUCTIONBASEINFO |
|
99 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
100 |
TYINGFLG NUMERIC(1,0) NOT NULL, |
|
101 |
CONSTRUCTIONYEAR NUMERIC(4,0) NOT NULL, |
|
102 |
CONSTRUCTIONPERIOD NUMERIC(4,0) NOT NULL, |
|
103 |
REQUESTEDDATE DATE, |
|
104 |
ESTIMATESSUBMITDEADLINE DATE, |
|
105 |
ESTIMATESSUBMITTEDDATE DATE, |
|
106 |
PROVISIONALORDERDATE DATE, |
|
107 |
ORDERDATE DATE, |
|
108 |
ORDERSTARTINGDATE DATE, |
|
109 |
ORDERCOMPLETIONDATE DATE, |
|
110 |
PREPARATIONSTARTDATE DATE, |
|
111 |
CONSTRUCTIONSTARTINGDATE DATE, |
|
112 |
CONSTRUCTIONCOMPLETIONDATE DATE, |
|
113 |
NONORDERDATE DATE, |
|
114 |
ORDERSDECISIONPRICE NUMERIC(12,2) NOT NULL, |
|
115 |
ORDERSDECISIONPRICEINTAX NUMERIC(12,2) NOT NULL, |
|
116 |
SALESPERSONCODE NUMERIC(8,0), |
|
117 |
CONSTRUCTIONPERSONCODE NUMERIC(8,0) NOT NULL, |
|
118 |
CONSTRSUBPERSONCODE NUMERIC(8,0) NOT NULL, |
|
119 |
CONSTRUCTIONINSTRUCTOR NUMERIC(8,0) NOT NULL, |
|
120 |
TRANSFERCONSTRUCTION NUMERIC(8,0) NOT NULL, |
|
121 |
TRANSFERCONSTRUCTIONDATE DATE, |
|
122 |
ORDERERSDIVISION NUMERIC(5,0) NOT NULL, |
|
123 |
ORDERERSCODE NUMERIC(5,0) NOT NULL, |
|
124 |
ESTIMATESEXPIRATIONDATE DATE, |
|
125 |
CONSTRUCTIONPERIODSTART DATE, |
|
126 |
CONSTRUCTIONPERIODEND DATE, |
|
127 |
CONSTRUCTIONPERIODSTART2 DATE, |
|
128 |
CONSTRUCTIONPERIODEND2 DATE, |
|
129 |
STARTDATE DATE, |
|
130 |
ENDDATE DATE, |
|
131 |
PURCHASEORDERMAILINGDATE DATE, |
|
132 |
PURCHASEORDERRETURNDATE DATE, |
|
133 |
PURCHASEORDERRETURNCHECKDATE DATE, |
|
134 |
CONSUMPTIONTAXFLG NUMERIC(1,0) NOT NULL, |
|
135 |
PRIMECONTRACTORFLG NUMERIC(1,0) NOT NULL, |
|
136 |
SALESCOSTFLG NUMERIC(1,0) NOT NULL, |
|
137 |
CONSTRUCTIONSTATUSFLG NUMERIC(2,0) NOT NULL, |
|
138 |
CONSTRUCTIONTYPE NUMERIC(5,0) NOT NULL, |
|
139 |
ESTIMATETYPE NUMERIC(1,0) NOT NULL, |
|
140 |
BILLINGSTARTDATE DATE NOT NULL, |
|
141 |
BILLINGDATE DATE NOT NULL, |
|
142 |
BILLINGSPLITFLG NUMERIC(1,0) NOT NULL, |
|
143 |
BILLINGSENDDATE DATE, |
|
144 |
LEDGERCOMPLATEDATE DATE NOT NULL, |
|
145 |
ENTRYDATE DATETIME NOT NULL, |
|
146 |
UPDATEDATE DATETIME NOT NULL, |
|
147 |
PRIMARY KEY (CONSTRUCTIONCODE) |
|
148 |
); |
|
75 |
-- ?H???????? |
|
76 |
drop table if exists constructionmaterialinfo cascade; |
|
149 | 77 |
|
150 |
CREATE TABLE CONSTRUCTIONBASEINFODETAIL |
|
151 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
152 |
DETAILNO NUMERIC(2,0) NOT NULL, |
|
153 |
DETAILSTRING VARCHAR(120), |
|
154 |
ENTRYDATE DATETIME NOT NULL, |
|
155 |
UPDATEDATE DATETIME NOT NULL, |
|
156 |
PRIMARY KEY (CONSTRUCTIONCODE, DETAILNO) |
|
157 |
); |
|
78 |
create table constructionmaterialinfo ( |
|
79 |
CONSTRUCTIONCODE int(10) unsigned default 0 not null comment '?H?????' |
|
80 |
, MATERIALITEMCODE smallint(5) unsigned default 0 not null comment '????i??R?[?h' |
|
81 |
, RENTCOUNT smallint(5) unsigned comment '??o??' |
|
82 |
, REPAYCOUNT smallint(5) unsigned comment '??p??' |
|
83 |
, COMPLETEFLG tinyint(3) unsigned comment '?????t???O' |
|
84 |
, ENTRYDATE datetime comment '?o?^???t' |
|
85 |
, UPDATEDATE datetime comment '?X?V???t' |
|
86 |
, constraint constructionmaterialinfo_PKC primary key (CONSTRUCTIONCODE,MATERIALITEMCODE) |
|
87 |
) comment '?H????????' ; |
|
158 | 88 |
|
159 |
CREATE TABLE CONSTRUCTIONBUDGET |
|
160 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
161 |
CREATORCODE NUMERIC(8,0) NOT NULL, |
|
162 |
CREATORNAME VARCHAR(60), |
|
163 |
CREATORCOSTS NUMERIC(11,3) NOT NULL, |
|
164 |
ASSISTANTCODE NUMERIC(8,0) NOT NULL, |
|
165 |
ASSISTANTNAME VARCHAR(60), |
|
166 |
ASSISTANTCOSTS NUMERIC(11,3) NOT NULL, |
|
167 |
INSTRUCTORCODE NUMERIC(8,0) NOT NULL, |
|
168 |
INSTRUCTORNAME VARCHAR(60), |
|
169 |
INSTRUCTORCOSTS NUMERIC(11,3) NOT NULL, |
|
170 |
CREATEDATE DATE NOT NULL, |
|
171 |
CONSTRUCTIONTIMES NUMERIC(5,2) NOT NULL, |
|
172 |
CONSTRUCTIONSTART DATE NOT NULL, |
|
173 |
CONSTRUCTIONEND DATE NOT NULL, |
|
174 |
INSTRUCTORTIMES NUMERIC(5,2) NOT NULL, |
|
175 |
SALARYFLG NUMERIC(1,0) NOT NULL, |
|
176 |
SALARYDAYS NUMERIC(4,0) NOT NULL, |
|
177 |
A_SALARYFLG NUMERIC(1,0) NOT NULL, |
|
178 |
A_SALARYDAYS NUMERIC(4,0) NOT NULL, |
|
179 |
I_SALARYFLG NUMERIC(1,0) NOT NULL, |
|
180 |
I_SALARYDAYS NUMERIC(4,0) NOT NULL, |
|
181 |
ENTRYDATE DATETIME NOT NULL, |
|
182 |
UPDATEDATE DATETIME NOT NULL, |
|
183 |
PRIMARY KEY (CONSTRUCTIONCODE) |
|
184 |
); |
|
89 |
-- ?????}?X?^ |
|
90 |
drop table if exists deadlinemaster cascade; |
|
185 | 91 |
|
186 |
CREATE TABLE CONSTRUCTIONBUDGETDETAIL |
|
187 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
188 |
GROUPCOUNT NUMERIC(2,0) NOT NULL, |
|
189 |
LINECOUNT NUMERIC(3,0) NOT NULL, |
|
190 |
COMPONENTCODE NUMERIC(5,0) NOT NULL, |
|
191 |
ITEMCODE NUMERIC(5,0) NOT NULL, |
|
192 |
FIRSTSTRING VARCHAR(120), |
|
193 |
SECONDSTRING VARCHAR(120), |
|
194 |
COMPANYTYPE NUMERIC(1,0) NOT NULL, |
|
195 |
COMPANYCODE NUMERIC(8,0) NOT NULL, |
|
196 |
COMPANYNAME VARCHAR(120), |
|
197 |
ESTIMATEPRICE NUMERIC(12,2) NOT NULL, |
|
198 |
NEGOTIATIONPRICE NUMERIC(12,2) NOT NULL, |
|
199 |
ORDERDESIREDAMOUNT NUMERIC(12,2) NOT NULL, |
|
200 |
EXECUTIONAMOUNT NUMERIC(12,2) NOT NULL, |
|
201 |
AMOUNTCONFIGRATE NUMERIC(5,2) NOT NULL, |
|
202 |
NEGOTIATEFLG NUMERIC(1,0) NOT NULL, |
|
203 |
ENTRYDATE DATETIME NOT NULL, |
|
204 |
UPDATEDATE DATETIME NOT NULL, |
|
205 |
PRIMARY KEY (CONSTRUCTIONCODE, GROUPCOUNT, LINECOUNT) |
|
206 |
); |
|
92 |
create table deadlinemaster ( |
|
93 |
LABOURKIND decimal(1,0) default '0' not null comment '??????' |
|
94 |
, DEADLINE decimal(2,0) comment '????' |
|
95 |
, PAYDAY decimal(2,0) comment '?x????' |
|
96 |
, NOTE varchar(120) comment '???l' |
|
97 |
, DELETEFLG decimal(1,0) comment '???t???O' |
|
98 |
, ENTRYDATE datetime comment '?o?^???t' |
|
99 |
, UPDATEDATE datetime comment '?X?V???t' |
|
100 |
, constraint deadlinemaster_PKC primary key (LABOURKIND) |
|
101 |
) comment '?????}?X?^' ; |
|
207 | 102 |
|
208 |
CREATE TABLE CONSTRUCTIONITEMMASTER |
|
209 |
( ITEMCODE NUMERIC(5,0) NOT NULL, |
|
210 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
211 |
ITEMNAME VARCHAR(120) DEFAULT '' NOT NULL, |
|
212 |
SUBITEMSFLG NUMERIC(1,0), |
|
213 |
MYEXPENSESFLG NUMERIC(1,0) NOT NULL, |
|
214 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
215 |
ENTRYDATE DATETIME NOT NULL, |
|
216 |
UPDATEDATE DATETIME NOT NULL, |
|
217 |
PRIMARY KEY (ITEMCODE) |
|
218 |
); |
|
103 |
-- ?????m?F???F?f?[?^ |
|
104 |
drop table if exists depositapprovalinfo cascade; |
|
219 | 105 |
|
220 |
CREATE TABLE CONSTRUCTIONLEDGER |
|
221 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
222 |
CONSTRUCTIONPERIOD NUMERIC(4,0) NOT NULL, |
|
223 |
CREATORCODE NUMERIC(8,0), |
|
224 |
CREATORNAME VARCHAR(60), |
|
225 |
CREATEDATE DATE NOT NULL, |
|
226 |
CONSTRUCTIONTIMES NUMERIC(5,2) NOT NULL, |
|
227 |
CONSTRUCTIONSTART DATE NOT NULL, |
|
228 |
CONSTRUCTIONEND DATE NOT NULL, |
|
229 |
ORDERSDECISIONPRICE NUMERIC(14,2) NOT NULL, |
|
230 |
COMPANYEXPENSES NUMERIC(10,2) NOT NULL, |
|
231 |
DEPARTMENTEXPENSES NUMERIC(10,2) NOT NULL, |
|
232 |
SALESEXPENSES NUMERIC(10,2) NOT NULL, |
|
233 |
TOTALPAYMENT NUMERIC(10,2) NOT NULL, |
|
234 |
GROSSPROFIT NUMERIC(10,2) NOT NULL, |
|
235 |
ALLOWANCE NUMERIC(10,2) NOT NULL, |
|
236 |
NETPROFIT NUMERIC(10,2) NOT NULL, |
|
237 |
COMPLATEFLG NUMERIC(1,0) NOT NULL, |
|
238 |
INTEGRATIONFLG NUMERIC(1,0) NOT NULL, |
|
239 |
ENTRYDATE DATETIME NOT NULL, |
|
240 |
UPDATEDATE DATETIME NOT NULL, |
|
241 |
PRIMARY KEY (CONSTRUCTIONCODE) |
|
242 |
); |
|
106 |
create table depositapprovalinfo ( |
|
107 |
ORDERERSDIVISION decimal(5,0) not null comment '???????' |
|
108 |
, ORDERERSCODE decimal(5,0) not null comment '??????R?[?h' |
|
109 |
, TARGETDATE decimal(6,0) not null comment '???N??' |
|
110 |
, SEQNO decimal(3,0) not null comment '?A??' |
|
111 |
, LINECOUNT decimal(3,0) not null comment '?s???' |
|
112 |
, APPROVALNO decimal(3,0) not null comment '???F????' |
|
113 |
, APPROVALPERSON decimal(8,0) comment '???F??R?[?h' |
|
114 |
, APPROVALPERSONNAME varchar(20) comment '???F???' |
|
115 |
, APPROVALAUTHORITY decimal(1,0) comment '???F??????' |
|
116 |
, APPROVALDATE date comment '???F???t' |
|
117 |
, ENTRYDATE datetime comment '?o?^???t' |
|
118 |
, UPDATEDATE datetime comment '?X?V???t' |
|
119 |
, constraint depositapprovalinfo_PKC primary key (ORDERERSDIVISION,ORDERERSCODE,TARGETDATE,SEQNO,LINECOUNT,APPROVALNO) |
|
120 |
) comment '?????m?F???F?f?[?^' ; |
|
243 | 121 |
|
244 |
CREATE TABLE CONSTRUCTIONLEDGERDETAIL |
|
245 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
246 |
GROUPCOUNT NUMERIC(2,0) NOT NULL, |
|
247 |
LINECOUNT NUMERIC(3,0) NOT NULL, |
|
248 |
COMPONENTCODE NUMERIC(5,0) NOT NULL, |
|
249 |
ITEMCODE NUMERIC(5,0) NOT NULL, |
|
250 |
FIRSTSTRING VARCHAR(120), |
|
251 |
SECONDSTRING VARCHAR(120), |
|
252 |
COMPANYTYPE NUMERIC(1,0) NOT NULL, |
|
253 |
COMPANYCODE NUMERIC(8,0) NOT NULL, |
|
254 |
COMPANYNAME VARCHAR(120), |
|
255 |
ESTIMATEPRICE NUMERIC(12,2) NOT NULL, |
|
256 |
EXECUTIONAMOUNT NUMERIC(12,2) NOT NULL, |
|
257 |
AMOUNTCONFIGRATE NUMERIC(5,2) NOT NULL, |
|
258 |
PAYMENTBURDEN NUMERIC(12,2) NOT NULL, |
|
259 |
FIXDATAFLG NUMERIC(1,0) NOT NULL, |
|
260 |
INDEPENDENTFLG NUMERIC(1,0) NOT NULL, |
|
261 |
FLUCTUATIONFLG NUMERIC(1,0) NOT NULL, |
|
262 |
SALARYFLG NUMERIC(1,0) NOT NULL, |
|
263 |
SALARYDAYS NUMERIC(4,0) NOT NULL, |
|
264 |
OPERATINGFLG NUMERIC(1,0) NOT NULL, |
|
265 |
ENTRYDATE DATETIME NOT NULL, |
|
266 |
UPDATEDATE DATETIME NOT NULL, |
|
267 |
PRIMARY KEY (CONSTRUCTIONCODE, GROUPCOUNT, LINECOUNT) |
|
268 |
); |
|
122 |
-- ?????f?[?^ |
|
123 |
drop table if exists depositdata cascade; |
|
269 | 124 |
|
270 |
CREATE TABLE CONSTRUCTIONLEDGEREXCUTE |
|
271 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
272 |
GROUPCOUNT NUMERIC(2,0) NOT NULL, |
|
273 |
LINECOUNT NUMERIC(3,0) NOT NULL, |
|
274 |
COLUMNCOUNT NUMERIC(3,0) NOT NULL, |
|
275 |
PAYMENTAMOUNT NUMERIC(12,2) NOT NULL, |
|
276 |
TARGETMONTH DATE NOT NULL, |
|
277 |
ENTRYDATE DATETIME NOT NULL, |
|
278 |
UPDATEDATE DATETIME NOT NULL, |
|
279 |
PRIMARY KEY (CONSTRUCTIONCODE, GROUPCOUNT, LINECOUNT, COLUMNCOUNT) |
|
280 |
); |
|
125 |
create table depositdata ( |
|
126 |
ORDERERSDIVISION decimal(5,0) not null comment '???????' |
|
127 |
, ORDERERSCODE decimal(5,0) not null comment '??????R?[?h' |
|
128 |
, TARGETDATE decimal(6,0) not null comment '???N??' |
|
129 |
, SEQNO decimal(3,0) not null comment '?A??' |
|
130 |
, BusinessPeriod decimal(4,0) comment '?c???' |
|
131 |
, DEPOSITDATE date comment '??????' |
|
132 |
, DepositAmount decimal(12,0) comment '???????z' |
|
133 |
, DEPOSITAMOUNTCASH decimal(10,0) comment '???????z?i?????j' |
|
134 |
, DEPOSITAMOUNTBILL decimal(10,0) comment '???????z?i??`?j' |
|
135 |
, ENTRYDATE datetime comment '?o?^???t' |
|
136 |
, UPDATEDATE datetime comment '?X?V???t' |
|
137 |
, constraint depositdata_PKC primary key (ORDERERSDIVISION,ORDERERSCODE,TARGETDATE,SEQNO) |
|
138 |
) comment '?????f?[?^' ; |
|
281 | 139 |
|
282 |
CREATE TABLE CONSTRUCTIONLINK |
|
283 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
284 |
FLUCTUATIONCODE NUMERIC(10,0) NOT NULL, |
|
285 |
ENTRYDATE DATETIME NOT NULL, |
|
286 |
UPDATEDATE DATETIME NOT NULL, |
|
287 |
PRIMARY KEY (CONSTRUCTIONCODE, FLUCTUATIONCODE) |
|
288 |
); |
|
140 |
-- ????????f?[?^ |
|
141 |
drop table if exists depositdatadetail cascade; |
|
289 | 142 |
|
290 |
CREATE TABLE CONSTRUCTIONPROGRESSDATE |
|
291 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
292 |
CONSTRUCTIONSTATUSFLG NUMERIC(2,0) NOT NULL, |
|
293 |
PREVIOUSSTATUSFLG NUMERIC(2,0), |
|
294 |
CHANGEDATE DATE NOT NULL, |
|
295 |
CHANGEPERSONCODE NUMERIC(8,0) NOT NULL, |
|
296 |
ENTRYDATE DATETIME NOT NULL, |
|
297 |
UPDATEDATE DATETIME NOT NULL, |
|
298 |
PRIMARY KEY (CONSTRUCTIONCODE, CONSTRUCTIONSTATUSFLG) |
|
299 |
); |
|
143 |
create table depositdatadetail ( |
|
144 |
ORDERERSDIVISION decimal(5,0) not null comment '???????' |
|
145 |
, ORDERERSCODE decimal(5,0) not null comment '??????R?[?h' |
|
146 |
, TARGETDATE decimal(6,0) not null comment '???N??' |
|
147 |
, SEQNO decimal(3,0) not null comment '?A??' |
|
148 |
, LINECOUNT decimal(3,0) not null comment '?s???' |
|
149 |
, REQUESTNO decimal(10,0) comment '????No' |
|
150 |
, ORDERNO decimal(2,0) comment '??t???' |
|
151 |
, DEPOSITAMOUNT decimal(10,0) comment '???????z' |
|
152 |
, DISCOUNTAMOUNT decimal(10,0) comment '?l???????z' |
|
153 |
, CNSTRPRICE decimal(10,0) comment '?????' |
|
154 |
, FEES decimal(10,0) comment '????' |
|
155 |
, OTHERADJUSTMENTS decimal(10,0) comment '?????????' |
|
156 |
, CARRYAMOUNT decimal(10,0) comment '?J?z???z' |
|
157 |
, APPROVALPERSONCODE decimal(8,0) comment '???F?S????R?[?h' |
|
158 |
, APPROVALDATE date comment '?S??????F???t' |
|
159 |
, APPROVALENDFLG decimal(1,0) comment '???F?????t???O' |
|
160 |
, ENTRYDATE datetime comment '?o?^???t' |
|
161 |
, UPDATEDATE datetime comment '?X?V???t' |
|
162 |
, constraint depositdatadetail_PKC primary key (ORDERERSDIVISION,ORDERERSCODE,TARGETDATE,SEQNO,LINECOUNT) |
|
163 |
) comment '????????f?[?^' ; |
|
300 | 164 |
|
301 |
CREATE TABLE CONSTRUCTIONSPECMASTER |
|
302 |
( ITEMCODE NUMERIC(5,0) NOT NULL, |
|
303 |
SPECCODE NUMERIC(5,0) NOT NULL, |
|
304 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
305 |
ITEMNAME VARCHAR(120) DEFAULT '', |
|
306 |
SPECNAME VARCHAR(120), |
|
307 |
UNITNAME VARCHAR(30), |
|
308 |
UNITPRICE NUMERIC(9,2) NOT NULL, |
|
309 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
310 |
ENTRYDATE DATETIME NOT NULL, |
|
311 |
UPDATEDATE DATETIME NOT NULL, |
|
312 |
PRIMARY KEY (ITEMCODE, SPECCODE) |
|
313 |
); |
|
165 |
-- ???????f?[?^ |
|
166 |
drop table if exists invoicedata cascade; |
|
314 | 167 |
|
315 |
CREATE TABLE CONSTRUCTIONSPECUNITPRICE |
|
316 |
( COMPONENTCODE NUMERIC(5,0) NOT NULL, |
|
317 |
ITEMCODE NUMERIC(5,0) NOT NULL, |
|
318 |
SPECCODE NUMERIC(5,0) NOT NULL, |
|
319 |
CONSTRUCTIONTYPECODE NUMERIC(5,0) NOT NULL, |
|
320 |
UNITPRICE NUMERIC(9,2) NOT NULL, |
|
321 |
ENTRYDATE DATETIME NOT NULL, |
|
322 |
UPDATEDATE DATETIME NOT NULL, |
|
323 |
PRIMARY KEY (COMPONENTCODE, ITEMCODE, SPECCODE, CONSTRUCTIONTYPECODE) |
|
324 |
); |
|
168 |
create table invoicedata ( |
|
169 |
INVOICENO decimal(9,0) not null comment '??????No' |
|
170 |
, ORDERERSDIVISION decimal(5,0) not null comment '???????' |
|
171 |
, ORDERERSCODE decimal(5,0) not null comment '??????R?[?h' |
|
172 |
, REQUESTMONTH decimal(6,0) not null comment '??????' |
|
173 |
, SEQNO decimal(2,0) not null comment '?A??' |
|
174 |
, CRETATEDATE date not null comment '????' |
|
175 |
, REQUESTDATE date not null comment '??????' |
|
176 |
, REQUESTNAME varchar(120) comment '??????' |
|
177 |
, TOTALAMOUNT decimal(10,0) comment '???????v???z' |
|
178 |
, TAXAMOUNT decimal(10,0) comment '???????z' |
|
179 |
, COMMENT1 varchar(60) comment '?R?????g1' |
|
180 |
, COMMENT2 varchar(60) comment '?R?????g2' |
|
181 |
, COMMENT3 varchar(60) not null comment '?R?????g3' |
|
182 |
, COMMENT4 varchar(60) not null comment '?R?????g4' |
|
183 |
, COMMENT5 varchar(60) not null comment '?R?????g5' |
|
184 |
, COMPLETEFLG decimal(1,0) default '0' not null comment '?????t???O' |
|
185 |
, ENTRYDATE datetime not null comment '?o?^?N????' |
|
186 |
, UPDATEDATE datetime not null comment '?X?V?N????' |
|
187 |
, constraint invoicedata_PKC primary key (INVOICENO) |
|
188 |
) comment '???????f?[?^' ; |
|
325 | 189 |
|
326 |
CREATE TABLE CONSTRUCTIONTYPEMASTER |
|
327 |
( TYPECODE NUMERIC(5,0) NOT NULL, |
|
328 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
329 |
NAMESTRING VARCHAR(100) DEFAULT '' NOT NULL, |
|
330 |
PUBLICFLG NUMERIC(1,0) NOT NULL, |
|
331 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
332 |
ENTRYDATE DATETIME NOT NULL, |
|
333 |
UPDATEDATE DATETIME NOT NULL, |
|
334 |
PRIMARY KEY (TYPECODE) |
|
335 |
); |
|
190 |
alter table invoicedata add unique ORDERERSDIVISION (ORDERERSDIVISION,ORDERERSCODE,REQUESTMONTH,SEQNO) ; |
|
336 | 191 |
|
337 |
CREATE TABLE COSTDATAOFPERSON |
|
338 |
( PERSONCODE NUMERIC(8,0) NOT NULL, |
|
339 |
ACTIONDATE DATE NOT NULL, |
|
340 |
DATATYPE NUMERIC(1,0) NOT NULL, |
|
341 |
DATAADDCOUNT NUMERIC(5,0) NOT NULL, |
|
342 |
TARGETMONTH VARCHAR(7) NOT NULL, |
|
343 |
CONSTRUCTIONCODE NUMERIC(10,0), |
|
344 |
SUPPLIERSCODE NUMERIC(5,0) NOT NULL, |
|
345 |
SUPPLIERSNAME VARCHAR(120), |
|
346 |
PAYMENTCONTENT VARCHAR(60), |
|
347 |
PAYMENTTYPE NUMERIC(1,0) NOT NULL, |
|
348 |
ENTRYPRICE NUMERIC(12,2) NOT NULL, |
|
349 |
COMPLATEFLG NUMERIC(1,0) NOT NULL, |
|
350 |
APPROVALFLG NUMERIC(1,0) NOT NULL, |
|
351 |
ENTRYDATE DATETIME NOT NULL, |
|
352 |
UPDATEDATE DATETIME NOT NULL, |
|
353 |
PRIMARY KEY (PERSONCODE, ACTIONDATE, DATATYPE, DATAADDCOUNT) |
|
354 |
); |
|
192 |
-- ?????? |
|
193 |
drop table if exists materialinfo cascade; |
|
355 | 194 |
|
356 |
CREATE TABLE DAILYDATACONSTRUCTION
|
|
357 |
( PERSONCODE NUMERIC(8,0) NOT NULL,
|
|
358 |
DAILYDATADATE DATE NOT NULL,
|
|
359 |
CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL,
|
|
360 |
WEATHER VARCHAR(60),
|
|
361 |
ENTRYDATE DATETIME NOT NULL,
|
|
362 |
UPDATEDATE DATETIME NOT NULL,
|
|
363 |
PRIMARY KEY (PERSONCODE, DAILYDATADATE, CONSTRUCTIONCODE)
|
|
364 |
); |
|
195 |
create table materialinfo (
|
|
196 |
MATERIALITEMCODE smallint(5) unsigned default 0 not null comment '????i??R?[?h'
|
|
197 |
, MATERIALCOUNT smallint(5) unsigned comment '?????'
|
|
198 |
, RENTCOUNT smallint(5) unsigned comment '??o??\??'
|
|
199 |
, DELETEFLG smallint(5) unsigned comment '???t???O'
|
|
200 |
, ENTRYDATE datetime comment '?o?^???t'
|
|
201 |
, UPDATEDATE datetime comment '?X?V???t'
|
|
202 |
, constraint materialinfo_PKC primary key (MATERIALITEMCODE)
|
|
203 |
) comment '??????' ;
|
|
365 | 204 |
|
366 |
CREATE TABLE DAILYDATADETAIL |
|
367 |
( PERSONCODE NUMERIC(8,0) NOT NULL, |
|
368 |
DAILYDATADATE DATE NOT NULL, |
|
369 |
CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
370 |
SEQNO NUMERIC(3,0) NOT NULL, |
|
371 |
JOBCATEGORYCODE NUMERIC(5,0) NOT NULL, |
|
372 |
COMPANYCODE NUMERIC(8,0) NOT NULL, |
|
373 |
TODAYHEADCOUNT NUMERIC(3,0) NOT NULL, |
|
374 |
TOTALHEADCOUNT NUMERIC(4,0) NOT NULL, |
|
375 |
TODAYWORK VARCHAR(100), |
|
376 |
NEXTDAYWORK VARCHAR(100), |
|
377 |
NEXTDAYHEADCOUNT NUMERIC(3,0) NOT NULL, |
|
378 |
ENTRYDATE DATETIME NOT NULL, |
|
379 |
UPDATEDATE DATETIME NOT NULL, |
|
380 |
PRIMARY KEY (PERSONCODE, DAILYDATADATE, CONSTRUCTIONCODE, SEQNO) |
|
381 |
); |
|
205 |
-- ????i??}?X?^ |
|
206 |
drop table if exists materialitemmaster cascade; |
|
382 | 207 |
|
383 |
CREATE TABLE DAILYDATAFIELD |
|
384 |
( PERSONCODE NUMERIC(8,0) NOT NULL, |
|
385 |
DAILYDATADATE DATE NOT NULL, |
|
386 |
CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
387 |
SEQNO NUMERIC(3,0) NOT NULL, |
|
388 |
PATROLTIME DATE NOT NULL, |
|
389 |
CONTENTSTEXT VARCHAR(200), |
|
390 |
ENTRYDATE DATETIME NOT NULL, |
|
391 |
UPDATEDATE DATETIME NOT NULL, |
|
392 |
PRIMARY KEY (PERSONCODE, DAILYDATADATE, CONSTRUCTIONCODE, SEQNO) |
|
393 |
); |
|
208 |
create table materialitemmaster ( |
|
209 |
MATERIALITEMCODE smallint(5) unsigned default 0 not null comment '????i??R?[?h' |
|
210 |
, MATERIALKINDCODE smallint(5) unsigned comment '??????R?[?h' |
|
211 |
, MATERIALITEMNAME varchar(40) comment '????i?????' |
|
212 |
, DISPLAYORDER smallint(5) unsigned comment '?\????' |
|
213 |
, DELETEFLG tinyint(3) unsigned comment '???t???O' |
|
214 |
, ENTRYDATE datetime comment '?o?^???t' |
|
215 |
, UPDATEDATE datetime comment '?X?V???t' |
|
216 |
, constraint materialitemmaster_PKC primary key (MATERIALITEMCODE) |
|
217 |
) comment '????i??}?X?^' ; |
|
394 | 218 |
|
395 |
CREATE TABLE DAILYDATAMATERIALS |
|
396 |
( PERSONCODE NUMERIC(8,0) NOT NULL, |
|
397 |
DAILYDATADATE DATE NOT NULL, |
|
398 |
CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
399 |
SEQNO NUMERIC(3,0) NOT NULL, |
|
400 |
MATERIALS VARCHAR(100), |
|
401 |
QUANTITY VARCHAR(100), |
|
402 |
PRODUCTION VARCHAR(100), |
|
403 |
DELIVERY VARCHAR(100), |
|
404 |
QUALITYCONTROL VARCHAR(100), |
|
405 |
ENTRYDATE DATETIME NOT NULL, |
|
406 |
UPDATEDATE DATETIME NOT NULL, |
|
407 |
PRIMARY KEY (PERSONCODE, DAILYDATADATE, CONSTRUCTIONCODE, SEQNO) |
|
408 |
); |
|
219 |
-- ??????}?X?^ |
|
220 |
drop table if exists materialkindmaster cascade; |
|
409 | 221 |
|
410 |
CREATE TABLE DAILYDATASUBCONTRACTORS |
|
411 |
( PERSONCODE NUMERIC(8,0) NOT NULL, |
|
412 |
DAILYDATADATE DATE NOT NULL, |
|
413 |
CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
414 |
SEQNO NUMERIC(3,0) NOT NULL, |
|
415 |
ATTENDEE VARCHAR(100), |
|
416 |
CONTENTSTEXT VARCHAR(200), |
|
417 |
ENTRYDATE DATETIME NOT NULL, |
|
418 |
UPDATEDATE DATETIME NOT NULL, |
|
419 |
PRIMARY KEY (PERSONCODE, DAILYDATADATE, CONSTRUCTIONCODE, SEQNO) |
|
420 |
); |
|
222 |
create table materialkindmaster ( |
|
223 |
MATERIALKINDCODE smallint(5) unsigned default 0 not null comment '??????R?[?h' |
|
224 |
, MATERIALKINDNAME varchar(40) comment '?????????' |
|
225 |
, DISPLAYORDER smallint(5) unsigned comment '?\????' |
|
226 |
, DELETEFLG tinyint(3) unsigned comment '???t???O' |
|
227 |
, ENTRYDATE datetime comment '?o?^???t' |
|
228 |
, UPDATEDATE datetime comment '?X?V???t' |
|
229 |
, constraint materialkindmaster_PKC primary key (MATERIALKINDCODE) |
|
230 |
) comment '??????}?X?^' ; |
|
421 | 231 |
|
422 |
CREATE TABLE DAILYDATAVEHICLES |
|
423 |
( PERSONCODE NUMERIC(8,0) NOT NULL, |
|
424 |
DAILYDATADATE DATE NOT NULL, |
|
425 |
CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
426 |
SEQNO NUMERIC(3,0) NOT NULL, |
|
427 |
MODEL VARCHAR(100), |
|
428 |
PERFORMANCE VARCHAR(100), |
|
429 |
OWNER VARCHAR(100), |
|
430 |
DRIVER VARCHAR(100), |
|
431 |
STARTWORKINGTIME DATE NOT NULL, |
|
432 |
ENDWORKINGTIME DATE NOT NULL, |
|
433 |
ENTRYDATE DATETIME NOT NULL, |
|
434 |
UPDATEDATE DATETIME NOT NULL, |
|
435 |
PRIMARY KEY (PERSONCODE, DAILYDATADATE, CONSTRUCTIONCODE, SEQNO) |
|
436 |
); |
|
232 |
-- ?????????? |
|
233 |
drop table if exists materialrecordinfo cascade; |
|
437 | 234 |
|
438 |
CREATE TABLE DEPARTMENTEXPENSESMASTER |
|
439 |
( DEPARTMENTCODE NUMERIC(5,0) NOT NULL, |
|
440 |
EXPENSESPERIOD NUMERIC(4,0) NOT NULL, |
|
441 |
NAMECODE NUMERIC(5,0) NOT NULL, |
|
442 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
443 |
EXPENSESRATIO NUMERIC(4,2) NOT NULL, |
|
444 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
445 |
ENTRYDATE DATETIME NOT NULL, |
|
446 |
UPDATEDATE DATETIME NOT NULL, |
|
447 |
PRIMARY KEY (DEPARTMENTCODE, EXPENSESPERIOD, NAMECODE) |
|
448 |
); |
|
235 |
create table materialrecordinfo ( |
|
236 |
MATERIALITEMCODE smallint(5) unsigned default 0 not null comment '????i??R?[?h' |
|
237 |
, PROCESSDATE date default '0000-00-00' not null comment '?????N????' |
|
238 |
, SEQNO smallint(5) unsigned default 0 not null comment '?A??' |
|
239 |
, RECKIND tinyint(3) unsigned comment '???R?[?h??' |
|
240 |
, CONSTRUCTIONCODE int(10) unsigned comment '?H?????' |
|
241 |
, PERSONCODE int(10) unsigned comment '?S????R?[?h' |
|
242 |
, MATERIALCOUNT smallint(5) unsigned comment '?????' |
|
243 |
, REPAYPLANDATE date comment '??p?\??N????' |
|
244 |
, COMMENTTEXT varchar(80) comment '?R?????g' |
|
245 |
, ENTRYDATE datetime comment '?o?^???t' |
|
246 |
, UPDATEDATE datetime comment '?X?V???t' |
|
247 |
, constraint materialrecordinfo_PKC primary key (MATERIALITEMCODE,PROCESSDATE,SEQNO) |
|
248 |
) comment '??????????' ; |
|
449 | 249 |
|
450 |
CREATE TABLE DEPARTMENTMASTER |
|
451 |
( DEPARTMENTCODE NUMERIC(5,0) NOT NULL, |
|
452 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
453 |
DEPARTMENTSTRING VARCHAR(100) DEFAULT '' NOT NULL, |
|
454 |
ACTIONSCHEDULEFLG NUMERIC(1,0) NOT NULL, |
|
455 |
STAFFASSIGNFLG NUMERIC(1,0) NOT NULL, |
|
456 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
457 |
ENTRYDATE DATETIME NOT NULL, |
|
458 |
UPDATEDATE DATETIME NOT NULL, |
|
459 |
PRIMARY KEY (DEPARTMENTCODE) |
|
460 |
); |
|
250 |
-- ?x?????F???f?[?^ |
|
251 |
drop table if exists paymentapprovalinfo cascade; |
|
461 | 252 |
|
462 |
CREATE TABLE DIVISIONMASTER |
|
463 |
( DIVISIONCODE NUMERIC(5,0) NOT NULL, |
|
464 |
NAMECODE NUMERIC(5,0) NOT NULL, |
|
465 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
466 |
NAMESTRING VARCHAR(100) DEFAULT '' NOT NULL, |
|
467 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
468 |
ENTRYDATE DATETIME NOT NULL, |
|
469 |
UPDATEDATE DATETIME NOT NULL, |
|
470 |
PRIMARY KEY (DIVISIONCODE, NAMECODE) |
|
471 |
); |
|
253 |
create table paymentapprovalinfo ( |
|
254 |
COMPANYCODE decimal(8,0) default '0' not null comment '??????R?[?h' |
|
255 |
, TARGETDATE decimal(6,0) default '0' not null comment '???N??' |
|
256 |
, SEQNO decimal(3,0) default '0' not null comment '?A??' |
|
257 |
, LINECOUNT decimal(3,0) default '0' not null comment '?s???' |
|
258 |
, APPROVALNO decimal(3,0) default '0' not null comment '???F????' |
|
259 |
, APPROVALPERSON decimal(8,0) comment '???F??R?[?h' |
|
260 |
, APPROVALPERSONNAME varchar(20) comment '???F???' |
|
261 |
, APPROVALAUTHORITY decimal(1,0) comment '???F??????' |
|
262 |
, APPROVALDATE date comment '???F???t' |
|
263 |
, ENTRYDATE datetime comment '?o?^???t' |
|
264 |
, UPDATEDATE datetime comment '?X?V???t' |
|
265 |
, constraint paymentapprovalinfo_PKC primary key (COMPANYCODE,TARGETDATE,SEQNO,LINECOUNT,APPROVALNO) |
|
266 |
) comment '?x?????F???f?[?^' ; |
|
472 | 267 |
|
473 |
CREATE TABLE ESTIMATEBUDGET |
|
474 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
475 |
CONSTRUCTIONTIME NUMERIC(5,2) NOT NULL, |
|
476 |
INTEGRATEDCODE NUMERIC(8,0) NOT NULL, |
|
477 |
DATACREATEDATE DATE NOT NULL, |
|
478 |
RETVALUE1 NUMERIC(12,2) NOT NULL, |
|
479 |
RETVALUE2 NUMERIC(12,2) NOT NULL, |
|
480 |
RETVALUE3 NUMERIC(12,2) NOT NULL, |
|
481 |
RETVALUE4 NUMERIC(12,2) NOT NULL, |
|
482 |
RETPERCENT NUMERIC(5,2) NOT NULL, |
|
483 |
ENTRYDATE DATETIME NOT NULL, |
|
484 |
UPDATEDATE DATETIME, |
|
485 |
PRIMARY KEY (CONSTRUCTIONCODE) |
|
486 |
); |
|
268 |
-- ?x??????f?[?^ |
|
269 |
drop table if exists paymentdatadetail cascade; |
|
487 | 270 |
|
488 |
CREATE TABLE ESTIMATEBUDGETDETAIL |
|
489 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
490 |
GROUPCOUNT NUMERIC(2,0) NOT NULL, |
|
491 |
LINECOUNT NUMERIC(3,0) NOT NULL, |
|
492 |
COMPONENTCODE NUMERIC(5,0) NOT NULL, |
|
493 |
ITEMCODE NUMERIC(5,0), |
|
494 |
COMPANYCODE NUMERIC(8,0) NOT NULL, |
|
495 |
FIRSTSTRING VARCHAR(120), |
|
496 |
SECONDSTRING VARCHAR(120), |
|
497 |
ESTIMATEPRICE NUMERIC(12,2) NOT NULL, |
|
498 |
NEGOTIATIONPRICE NUMERIC(12,2) NOT NULL, |
|
499 |
NOTES VARCHAR(120), |
|
500 |
ENTRYDATE DATETIME NOT NULL, |
|
501 |
UPDATEDATE DATETIME NOT NULL, |
|
502 |
PRIMARY KEY (CONSTRUCTIONCODE, GROUPCOUNT, LINECOUNT) |
|
503 |
); |
|
271 |
create table paymentdatadetail ( |
|
272 |
COMPANYCODE decimal(8,0) default '0' not null comment '??????R?[?h' |
|
273 |
, TARGETDATE decimal(6,0) default '0' not null comment '???N??' |
|
274 |
, SEQNO decimal(3,0) default '0' not null comment '?A??' |
|
275 |
, LINECOUNT decimal(3,0) default '0' not null comment '?s???' |
|
276 |
, BILLPRICE decimal(10,0) comment '???????z' |
|
277 |
, DISCOUNTPRICE decimal(10,0) comment '?l???????z' |
|
278 |
, OFFSETPRICE decimal(10,0) comment '???E???z' |
|
279 |
, NEXTCOPRICE decimal(10,0) comment '????J?z' |
|
280 |
, HIGHWPRICE decimal(10,0) comment '??????' |
|
281 |
, HARDWPRICE decimal(10,0) comment '??????' |
|
282 |
, INDSWASTETAX decimal(10,0) comment '?Y?p??' |
|
283 |
, CNSTRPRICE decimal(10,0) comment '?????' |
|
284 |
, CNSTRPRICEEXIST decimal(1,0) comment '??????L??' |
|
285 |
, APPROVALPERSONCODE decimal(8,0) comment '???F?S????R?[?h' |
|
286 |
, APPROVALDATE date comment '?S??????F???t' |
|
287 |
, APPROVALENDFLG decimal(1,0) comment '???F?????t???O' |
|
288 |
, ENTRYDATE datetime comment '?o?^???t' |
|
289 |
, UPDATEDATE datetime comment '?X?V???t' |
|
290 |
, constraint paymentdatadetail_PKC primary key (COMPANYCODE,TARGETDATE,SEQNO,LINECOUNT) |
|
291 |
) comment '?x??????f?[?^' ; |
|
504 | 292 |
|
505 |
CREATE TABLE ESTIMATEDATA |
|
506 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
507 |
LINECOUNT NUMERIC(3,0) NOT NULL, |
|
508 |
COMPONENTCODE NUMERIC(3,0) NOT NULL, |
|
509 |
FIXEDITEMCODE VARCHAR(1), |
|
510 |
ITEMNAME VARCHAR(120), |
|
511 |
WORKNAME VARCHAR(120), |
|
512 |
PRICEVALUE NUMERIC(14,2) NOT NULL, |
|
513 |
NOTE VARCHAR(60), |
|
514 |
MYEXPENSESFLG NUMERIC(1,0) NOT NULL, |
|
515 |
INPUTFLG NUMERIC(1,0) NOT NULL, |
|
516 |
ENTRYDATE DATETIME NOT NULL, |
|
517 |
UPDATEDATE DATETIME NOT NULL, |
|
518 |
PRIMARY KEY (CONSTRUCTIONCODE, LINECOUNT) |
|
519 |
); |
|
293 |
-- ?????f?[?^ |
|
294 |
drop table if exists requestdata cascade; |
|
520 | 295 |
|
521 |
CREATE TABLE ESTIMATEDATABODY |
|
522 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
523 |
PAGECOUNT NUMERIC(4,0) NOT NULL, |
|
524 |
CATEGORY NUMERIC(1,0) NOT NULL, |
|
525 |
UNIONCOMPONENTCODE NUMERIC(5,0) NOT NULL, |
|
526 |
COMPONENTCODE NUMERIC(5,0) NOT NULL, |
|
527 |
ITEMCODE NUMERIC(5,0) NOT NULL, |
|
528 |
SELECTCOMPONENT NUMERIC(5,0) NOT NULL, |
|
529 |
PAGETITLE VARCHAR(120) NOT NULL, |
|
530 |
DETAILLINECOUNT NUMERIC(3,0) NOT NULL, |
|
531 |
ENTRYDATE DATETIME NOT NULL, |
|
532 |
UPDATEDATE DATETIME NOT NULL, |
|
533 |
PRIMARY KEY (CONSTRUCTIONCODE, PAGECOUNT) |
|
534 |
); |
|
296 |
create table requestdata ( |
|
297 |
REQUESTNO decimal(9,0) not null comment '????No' |
|
298 |
, MAINCONSTRUCTIONCODE decimal(10,0) not null comment '?{?H?????' |
|
299 |
, CONSTRUCTIONNAME varchar(120) not null comment '?H??????' |
|
300 |
, CONTRACTAMOUNT decimal(10,0) not null comment '???????z' |
|
301 |
, PAIDAMOUNT decimal(10,0) not null comment '????????z' |
|
302 |
, REQUESTAMOUNT0 decimal(10,0) not null comment '???????z?O' |
|
303 |
, REQUESTAMOUNT1 decimal(10,0) not null comment '???????z?P' |
|
304 |
, REQUESTAMOUNT2 decimal(10,0) comment '???????z?Q' |
|
305 |
, REQUESTAMOUNT3 decimal(10,0) comment '???????z?R' |
|
306 |
, REQUESTAMOUNT4 decimal(10,0) comment '???????z?S' |
|
307 |
, REQUESTAMOUNT5 decimal(10,0) comment '???????z?T' |
|
308 |
, REQUESTAMOUNT6 decimal(10,0) comment '???????z?U' |
|
309 |
, UNCLAIMEDAMOUNT decimal(10,0) not null comment '?????c???z' |
|
310 |
, UNPAIDAMOUNT decimal(10,0) not null comment '?????????z' |
|
311 |
, TAXAMOUNT decimal(10,0) not null comment '?????' |
|
312 |
, NOTE varchar(120) not null comment '???l' |
|
313 |
, ENTRYDATE datetime not null comment '?o?^?N????' |
|
314 |
, UPDATEDATE datetime not null comment '?X?V?N????' |
|
315 |
, constraint requestdata_PKC primary key (REQUESTNO,MAINCONSTRUCTIONCODE) |
|
316 |
) comment '?????f?[?^' ; |
|
535 | 317 |
|
536 |
CREATE TABLE ESTIMATEDATADETAIL |
|
537 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
538 |
PAGECOUNT NUMERIC(4,0) NOT NULL, |
|
539 |
LINECOUNT NUMERIC(3,0) NOT NULL, |
|
540 |
DATATYPE NUMERIC(1,0) NOT NULL, |
|
541 |
COMPONENTCODE NUMERIC(5,0) NOT NULL, |
|
542 |
ITEMCODE NUMERIC(5,0) NOT NULL, |
|
543 |
SPECCODE NUMERIC(5,0) NOT NULL, |
|
544 |
ITEMNAME VARCHAR(120), |
|
545 |
SPECNAME VARCHAR(120), |
|
546 |
UNITCOUNT NUMERIC(8,2) NOT NULL, |
|
547 |
UNITNAME VARCHAR(30), |
|
548 |
UNITPRICE NUMERIC(9,2) NOT NULL, |
|
549 |
LINETOTAL NUMERIC(12,2) NOT NULL, |
|
550 |
NOTE VARCHAR(60), |
|
551 |
COMPANYCODE NUMERIC(8,0) NOT NULL, |
|
552 |
MYEXPENSESFLG NUMERIC(1,0) NOT NULL, |
|
553 |
INPUTFLG NUMERIC(1,0), |
|
554 |
ENTRYDATE DATETIME NOT NULL, |
|
555 |
UPDATEDATE DATETIME NOT NULL, |
|
556 |
PRIMARY KEY (CONSTRUCTIONCODE, PAGECOUNT, LINECOUNT) |
|
557 |
); |
|
318 |
-- ?????f?[?^???? |
|
319 |
drop table if exists requestdatadetail cascade; |
|
558 | 320 |
|
559 |
CREATE TABLE EXPENSESMASTER |
|
560 |
( DIVISIONCODE NUMERIC(5,0) NOT NULL, |
|
561 |
NAMECODE NUMERIC(5,0) NOT NULL, |
|
562 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
563 |
EXPENSESRATIO NUMERIC(4,2) NOT NULL, |
|
564 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
565 |
ENTRYDATE DATETIME NOT NULL, |
|
566 |
UPDATEDATE DATETIME NOT NULL, |
|
567 |
PRIMARY KEY (DIVISIONCODE, NAMECODE) |
|
568 |
); |
|
321 |
create table requestdatadetail ( |
|
322 |
REQUESTNO decimal(9,0) not null comment '????No' |
|
323 |
, MAINCONSTRUCTIONCODE decimal(10,0) not null comment '?{?H?????' |
|
324 |
, CONSTRUCTIONCODE decimal(10,0) not null comment '?H?????' |
|
325 |
, CONSTRUCTIONKIND decimal(1,0) not null comment '?H????' |
|
326 |
, REQUESTAMOUNT decimal(10,0) not null comment '???????z' |
|
327 |
, TAXAMOUNT decimal(10,0) not null comment '?????' |
|
328 |
, ENTRYDATE datetime not null comment '?o?^?N????' |
|
329 |
, UPDATEDATE datetime not null comment '?X?V?N????' |
|
330 |
, constraint requestdatadetail_PKC primary key (REQUESTNO,MAINCONSTRUCTIONCODE,CONSTRUCTIONCODE,CONSTRUCTIONKIND) |
|
331 |
) comment '?????f?[?^????' ; |
|
569 | 332 |
|
570 |
CREATE TABLE HOLIDAYCALENDERMASTER |
|
571 |
( HOLIDAY DATE NOT NULL, |
|
572 |
BUSINESSYEAR NUMERIC(4,0) NOT NULL, |
|
573 |
TARGETMONTH NUMERIC(2,0) NOT NULL, |
|
574 |
TARGETDAY NUMERIC(2,0) NOT NULL, |
|
575 |
PRIMARY KEY (HOLIDAY) |
|
576 |
); |
|
333 |
-- ?????w?b?_ |
|
334 |
drop table if exists requesthead cascade; |
|
577 | 335 |
|
578 |
CREATE TABLE INPUTSEARCHLOGDATA |
|
579 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
580 |
USEDPROCESSNO NUMERIC(3,0) NOT NULL, |
|
581 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
582 |
DATATYPE NUMERIC(1,0) NOT NULL, |
|
583 |
INPUTCODE NUMERIC(10,0), |
|
584 |
PRIMARY KEY (CONSTRUCTIONCODE, USEDPROCESSNO, DISPLAYORDER) |
|
585 |
); |
|
336 |
create table requesthead ( |
|
337 |
REQUESTNO decimal(9,0) not null comment '????No' |
|
338 |
, REQCONSTRUCTIONCODE decimal(10,0) not null comment '?????H?????' |
|
339 |
, ORDERNO decimal(2,0) not null comment '??t???' |
|
340 |
, REQUESTMONTH decimal(6,0) not null comment '??????' |
|
341 |
, ORDERERSDIVISION decimal(5,0) not null comment '???????' |
|
342 |
, ORDERERSCODE decimal(5,0) not null comment '??????R?[?h' |
|
343 |
, ORDERERSNAME varchar(120) not null comment '???????' |
|
344 |
, REQCONSTRUCTIONNAME varchar(120) not null comment '?????H??????' |
|
345 |
, REQUESTTOTALAMOUNT decimal(10,0) not null comment '???????z???v' |
|
346 |
, REQUESTAMOUNT decimal(10,0) not null comment '???????z' |
|
347 |
, TAXAMOUNT decimal(10,0) not null comment '?????' |
|
348 |
, UNPAIDAMOUNT decimal(10,0) comment '??????' |
|
349 |
, NOTE varchar(120) comment '???l' |
|
350 |
, ASSIGNEDFLG decimal(1,0) comment '??????t???O' |
|
351 |
, INVOICENO decimal(9,0) not null comment '??????No' |
|
352 |
, ENTRYDATE datetime not null comment '?o?^?N????' |
|
353 |
, UPDATEDATE datetime not null comment '?X?V?N????' |
|
354 |
, constraint requesthead_PKC primary key (REQUESTNO) |
|
355 |
) comment '?????w?b?_' ; |
|
586 | 356 |
|
587 |
CREATE TABLE MESSAGEBOARDDATA |
|
588 |
( RECORDNUMBER NUMERIC(6,0) NOT NULL, |
|
589 |
BRANCHNUMBER NUMERIC(3,0) NOT NULL, |
|
590 |
FROMCODE NUMERIC(8,0) NOT NULL, |
|
591 |
FROMNAME VARCHAR(60) NOT NULL, |
|
592 |
MESSAGETITILE VARCHAR(100), |
|
593 |
MESSAGECONTENT VARCHAR(1333) NOT NULL, |
|
594 |
LINKTYPE NUMERIC(2,0) NOT NULL, |
|
595 |
LINKMESSAGE VARCHAR(200), |
|
596 |
LINKCODE VARCHAR(30), |
|
597 |
WRITINGDATE DATE NOT NULL, |
|
598 |
PERSONCODE NUMERIC(8,0) NOT NULL, |
|
599 |
SHAREFLAG NUMERIC(2,0) NOT NULL, |
|
600 |
MESSAGECOLOR VARCHAR(8), |
|
601 |
BACKCOLOR VARCHAR(8), |
|
602 |
MESSAGEFLAG NUMERIC(1,0) NOT NULL, |
|
603 |
ENTRYDATE DATETIME, |
|
604 |
UPDATEDATE DATETIME, |
|
605 |
PRIMARY KEY (RECORDNUMBER, BRANCHNUMBER) |
|
606 |
); |
|
357 |
alter table requesthead add unique REQCONSTRUCTIONCODE (REQCONSTRUCTIONCODE,ORDERNO) ; |
|
607 | 358 |
|
608 |
CREATE TABLE MESSAGEBOARDTERGET |
|
609 |
( RECORDNUMBER NUMERIC(6,0) NOT NULL, |
|
610 |
BRANCHNUMBER NUMERIC(3,0) NOT NULL, |
|
611 |
SEQNUM NUMERIC(3,0) NOT NULL, |
|
612 |
TOCODE NUMERIC(8,0) NOT NULL, |
|
613 |
TONAME VARCHAR(60) NOT NULL, |
|
614 |
ENTRYDATE DATETIME, |
|
615 |
UPDATEDATE DATETIME, |
|
616 |
PRIMARY KEY (RECORDNUMBER, BRANCHNUMBER, SEQNUM) |
|
617 |
); |
|
618 |
|
|
619 |
CREATE TABLE MESSAGEBROWSINGHISTORY |
|
620 |
( RECORDNUMBER NUMERIC(6,0) NOT NULL, |
|
621 |
BRANCHNUMBER NUMERIC(3,0) NOT NULL, |
|
622 |
SEQNUM NUMERIC(3,0) NOT NULL, |
|
623 |
BROWSINGCODE NUMERIC(8,0) NOT NULL, |
|
624 |
BROWSINGDATE DATE NOT NULL, |
|
625 |
ENTRYDATE DATETIME, |
|
626 |
UPDATEDATE DATETIME, |
|
627 |
PRIMARY KEY (RECORDNUMBER, BRANCHNUMBER, SEQNUM) |
|
628 |
); |
|
629 |
|
|
630 |
CREATE TABLE ORDERERSMASTER |
|
631 |
( ORDERCOTEGORY NUMERIC(5,0) NOT NULL, |
|
632 |
ORDERERSCODE NUMERIC(5,0) NOT NULL, |
|
633 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
634 |
CORPORATESTATUSNAME VARCHAR(100), |
|
635 |
CORPORATESTATUSPOINT NUMERIC(1,0), |
|
636 |
ORDERERSNAME1 VARCHAR(60) DEFAULT '' NOT NULL, |
|
637 |
ORDERERSNAME2 VARCHAR(60), |
|
638 |
ZIPCODE VARCHAR(8), |
|
639 |
ADDRESS1 VARCHAR(60), |
|
640 |
ADDRESS2 VARCHAR(60) DEFAULT '', |
|
641 |
ADDRESS3 VARCHAR(60), |
|
642 |
PHONENUMBER VARCHAR(13) DEFAULT '', |
|
643 |
FAXNUMBER VARCHAR(13) DEFAULT '', |
|
644 |
NOTE VARCHAR(300) DEFAULT '', |
|
645 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
646 |
ENTRYDATE DATETIME NOT NULL, |
|
647 |
UPDATEDATE DATETIME NOT NULL, |
|
648 |
PRIMARY KEY (ORDERCOTEGORY, ORDERERSCODE) |
|
649 |
); |
|
650 |
|
|
651 |
CREATE TABLE ORDERSPRICEDATA |
|
652 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
653 |
CHANGENO NUMERIC(3,0) NOT NULL, |
|
654 |
CHANGEDATE DATE NOT NULL, |
|
655 |
CHANGEPERSONCODE NUMERIC(8,0) NOT NULL, |
|
656 |
CHANGEPERSONNAME VARCHAR(60), |
|
657 |
BEFOREVALUE NUMERIC(14,2) NOT NULL, |
|
658 |
BEFOREVALUEINTAX NUMERIC(14,2) NOT NULL, |
|
659 |
AFTERVALUE NUMERIC(14,2) NOT NULL, |
|
660 |
AFTERVALUEINTAX NUMERIC(14,2) NOT NULL, |
|
661 |
CHANGECOMMENT VARCHAR(200), |
|
662 |
ENTRYDATE DATETIME, |
|
663 |
UPDATEDATE DATETIME, |
|
664 |
PRIMARY KEY (CONSTRUCTIONCODE, CHANGENO) |
|
665 |
); |
|
666 |
|
|
667 |
CREATE TABLE PERSONINCHARGEMASTER |
|
668 |
( PERSONCODE NUMERIC(8,0) NOT NULL, |
|
669 |
DISPLAYORDER NUMERIC(8,0) NOT NULL, |
|
670 |
PERSONNAME VARCHAR(60) DEFAULT '' NOT NULL, |
|
671 |
STARTDATE DATE NOT NULL, |
|
672 |
ENDDATE DATE, |
|
673 |
PASSWORD VARCHAR(16), |
|
674 |
SECURITYMANAGEMENT NUMERIC(1,0) NOT NULL, |
|
675 |
MSGBACKCOLOR VARCHAR(8), |
|
676 |
DISPLAYSTRING VARCHAR(20), |
|
677 |
DEPARTMENTCODE NUMERIC(5,0), |
|
678 |
MONTHLYSALARY NUMERIC(11,3) NOT NULL, |
|
679 |
YEARSALARY NUMERIC(12,3) NOT NULL, |
|
680 |
QUALIFICATION VARCHAR(120), |
|
681 |
SEALPRINTNAME VARCHAR(5), |
|
682 |
EMPLOYEECLASSFLG NUMERIC(1,0) NOT NULL, |
|
683 |
LEDGERFLG NUMERIC(1,0) NOT NULL, |
|
684 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
685 |
ENTRYDATE DATETIME NOT NULL, |
|
686 |
UPDATEDATE DATETIME NOT NULL, |
|
687 |
PRIMARY KEY (PERSONCODE) |
|
688 |
); |
|
689 |
|
|
690 |
CREATE TABLE POINTINGOUTCOMMENT |
|
691 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
692 |
PROCESSNO NUMERIC(3,0) NOT NULL, |
|
693 |
SEQNO NUMERIC(3,0) NOT NULL, |
|
694 |
PAGECOUNT NUMERIC(4,0) NOT NULL, |
|
695 |
PERSONCODE NUMERIC(8,0) NOT NULL, |
|
696 |
DROWCOLOR VARCHAR(8), |
|
697 |
COMMENTMESSAGE VARCHAR(1000), |
|
698 |
STARTPOINTX NUMERIC(4,0) NOT NULL, |
|
699 |
STARTPOINTY NUMERIC(4,0) NOT NULL, |
|
700 |
CURRENTPOINTX NUMERIC(4,0) NOT NULL, |
|
701 |
CURRENTPOINTY NUMERIC(4,0) NOT NULL, |
|
702 |
CURRENTWIDTH NUMERIC(4,0) NOT NULL, |
|
703 |
CURRENTHEIGHT NUMERIC(4,0) NOT NULL, |
|
704 |
ENTRYDATE DATETIME NOT NULL, |
|
705 |
UPDATEDATE DATETIME NOT NULL, |
|
706 |
PRIMARY KEY (CONSTRUCTIONCODE, PROCESSNO, SEQNO) |
|
707 |
); |
|
708 |
|
|
709 |
CREATE TABLE PROCEEDINGSDATA |
|
710 |
( PERSONCODE NUMERIC(8,0) NOT NULL, |
|
711 |
PROCEEDINGSDATADATE DATE NOT NULL, |
|
712 |
CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
713 |
STARTMEETINGTIME DATE NOT NULL, |
|
714 |
ENDMEETINGTIME DATE NOT NULL, |
|
715 |
MEETINGPALCE1 VARCHAR(100), |
|
716 |
MEETINGPALCE2 VARCHAR(100), |
|
717 |
MEETINGPALCE3 VARCHAR(100), |
|
718 |
ENTRYDATE DATETIME NOT NULL, |
|
719 |
UPDATEDATE DATETIME NOT NULL, |
|
720 |
PRIMARY KEY (PERSONCODE, PROCEEDINGSDATADATE, CONSTRUCTIONCODE) |
|
721 |
); |
|
722 |
|
|
723 |
CREATE TABLE PROCEEDINGSDATAATTENDEE |
|
724 |
( PERSONCODE NUMERIC(8,0) NOT NULL, |
|
725 |
PROCEEDINGSDATADATE DATE NOT NULL, |
|
726 |
CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
727 |
SEQNO NUMERIC(3,0) NOT NULL, |
|
728 |
DEPARTMENT VARCHAR(100), |
|
729 |
ATTENDEENAME VARCHAR(100), |
|
730 |
ENTRYDATE DATETIME NOT NULL, |
|
731 |
UPDATEDATE DATETIME NOT NULL, |
|
732 |
PRIMARY KEY (PERSONCODE, PROCEEDINGSDATADATE, CONSTRUCTIONCODE, SEQNO) |
|
733 |
); |
|
734 |
|
|
735 |
CREATE TABLE PROCEEDINGSDATADETAIL |
|
736 |
( PERSONCODE NUMERIC(8,0) NOT NULL, |
|
737 |
PROCEEDINGSDATADATE DATE NOT NULL, |
|
738 |
CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
739 |
SEQNO NUMERIC(3,0) NOT NULL, |
|
740 |
TITILENO NUMERIC(3,0), |
|
741 |
TITILE VARCHAR(100), |
|
742 |
CONTENTSTEXT VARCHAR(200), |
|
743 |
ENTRYDATE DATETIME NOT NULL, |
|
744 |
UPDATEDATE DATETIME NOT NULL, |
|
745 |
PRIMARY KEY (PERSONCODE, PROCEEDINGSDATADATE, CONSTRUCTIONCODE, SEQNO) |
|
746 |
); |
|
747 |
|
|
748 |
CREATE TABLE PROCESSAPPROVAL |
|
749 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
750 |
APPROVALCODE NUMERIC(3,0) NOT NULL, |
|
751 |
SEQNO NUMERIC(2,0) NOT NULL, |
|
752 |
PERSONCODE NUMERIC(8,0) NOT NULL, |
|
753 |
PETITIONAPPROVALDATE DATE NOT NULL, |
|
754 |
APPROVALLIMITDATES DATE NOT NULL, |
|
755 |
APPROVALSTATUS NUMERIC(1,0) NOT NULL, |
|
756 |
INPUTCOMMENT VARCHAR(300), |
|
757 |
ENTRYDATE DATETIME NOT NULL, |
|
758 |
UPDATEDATE DATETIME NOT NULL, |
|
759 |
PRIMARY KEY (CONSTRUCTIONCODE, APPROVALCODE, SEQNO) |
|
760 |
); |
|
761 |
|
|
762 |
CREATE TABLE PURCHASEORDER |
|
763 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
764 |
SEQNO NUMERIC(3,0) NOT NULL, |
|
765 |
COMPANYCODE NUMERIC(8,0) NOT NULL, |
|
766 |
CREATEDATE DATE, |
|
767 |
ORDERPRICE NUMERIC(12,2) NOT NULL, |
|
768 |
LASTROWSTRINGDATE DATE NOT NULL, |
|
769 |
ORDERSHEETTYPE NUMERIC(1,0) NOT NULL, |
|
770 |
PAYMENTTERMS NUMERIC(1,0) NOT NULL, |
|
771 |
CASHRATIO NUMERIC(4,1) NOT NULL, |
|
772 |
BILLPERIOD NUMERIC(4,0) NOT NULL, |
|
773 |
PREPAYMENTS NUMERIC(1,0) NOT NULL, |
|
774 |
PREPAYMENTSDAYS NUMERIC(3,0) NOT NULL, |
|
775 |
PREPAYMENTSPRICE NUMERIC(12,2) NOT NULL, |
|
776 |
PARTIALPAYMENT NUMERIC(1,0) NOT NULL, |
|
777 |
PARTIALPAYMENTMOUNTH NUMERIC(2,0) NOT NULL, |
|
778 |
PARTIALPAYMENTDAY1 NUMERIC(2,0) NOT NULL, |
|
779 |
PARTIALPAYMENTDAY2 NUMERIC(2,0) NOT NULL, |
|
780 |
PARTIALPAYMENTPRICE NUMERIC(12,2) NOT NULL, |
|
781 |
COMPLETIONPAYMENT NUMERIC(1,0) NOT NULL, |
|
782 |
COMPLETIONPAYMENTDAYS NUMERIC(3,0) NOT NULL, |
|
783 |
COMPLETIONPAYMENTPRICE NUMERIC(12,2) NOT NULL, |
|
784 |
LEADENGINEERCODE NUMERIC(8,0), |
|
785 |
LEADENGINEERNAME VARCHAR(60), |
|
786 |
SAFETYOFFICERCODE NUMERIC(8,0), |
|
787 |
SAFETYOFFICERNAME VARCHAR(60), |
|
788 |
WORKERSCOUNT NUMERIC(3,0), |
|
789 |
PRINTOUTDATE DATE NOT NULL, |
|
790 |
ENTRYDATE DATETIME NOT NULL, |
|
791 |
UPDATEDATE DATETIME NOT NULL, |
|
792 |
PRIMARY KEY (CONSTRUCTIONCODE, SEQNO) |
|
793 |
); |
|
794 |
|
|
795 |
CREATE TABLE PURCHASEORDERDETAIL |
|
796 |
( CONSTRUCTIONCODE NUMERIC(10,0) NOT NULL, |
|
797 |
SEQNO NUMERIC(3,0) NOT NULL, |
|
798 |
GROUPCOUNT NUMERIC(1,0) NOT NULL, |
|
799 |
LINECOUNT NUMERIC(3,0) NOT NULL, |
|
800 |
COMPONENTCODE NUMERIC(5,0) NOT NULL, |
|
801 |
ITEMCODE NUMERIC(5,0) NOT NULL, |
|
802 |
FIRSTSTRING VARCHAR(120), |
|
803 |
SECONDSTRING VARCHAR(120), |
|
804 |
UNITCOUNT NUMERIC(8,2) NOT NULL, |
|
805 |
UNITNAME VARCHAR(30), |
|
806 |
UNITPRICE NUMERIC(10,2) NOT NULL, |
|
807 |
ORDERSLINEPRICE NUMERIC(12,2), |
|
808 |
ENTRYDATE DATETIME NOT NULL, |
|
809 |
UPDATEDATE DATETIME NOT NULL, |
|
810 |
PRIMARY KEY (CONSTRUCTIONCODE, SEQNO, GROUPCOUNT, LINECOUNT) |
|
811 |
); |
|
812 |
|
|
813 |
CREATE TABLE SALESGRAPHDATA |
|
814 |
( GRAPHDATACODE NUMERIC(8,0) NOT NULL, |
|
815 |
CONSTRUCTIONPERIOD NUMERIC(4,0) NOT NULL, |
|
816 |
SALESDATADAYS DATE NOT NULL, |
|
817 |
DISPLAYORDER NUMERIC(8,0) NOT NULL, |
|
818 |
DATANAME VARCHAR(100) NOT NULL, |
|
819 |
SALESAMOUNT NUMERIC(10,0) NOT NULL, |
|
820 |
ADMINISTRATIVEEXPENSE NUMERIC(10,0) NOT NULL, |
|
821 |
GROSSPROFIT NUMERIC(10,0) NOT NULL, |
|
822 |
NETINCOME NUMERIC(10,0) NOT NULL, |
|
823 |
ENTRYDATE DATETIME NOT NULL, |
|
824 |
UPDATEDATE DATETIME NOT NULL, |
|
825 |
PRIMARY KEY (GRAPHDATACODE, CONSTRUCTIONPERIOD, SALESDATADAYS) |
|
826 |
); |
|
827 |
|
|
828 |
CREATE TABLE SUBCONTRACTORITEMMASTER |
|
829 |
( ITEMCODE NUMERIC(5,0) NOT NULL, |
|
830 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
831 |
ITEMNAME VARCHAR(120) DEFAULT '' NOT NULL, |
|
832 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
833 |
ENTRYDATE DATETIME NOT NULL, |
|
834 |
UPDATEDATE DATETIME NOT NULL, |
|
835 |
PRIMARY KEY (ITEMCODE) |
|
836 |
); |
|
837 |
|
|
838 |
CREATE TABLE SUBCONTRACTORJOBCATEGORY |
|
839 |
( JOBCATEGORYCODE NUMERIC(5,0) NOT NULL, |
|
840 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
841 |
JOBCATEGORYNAME VARCHAR(120) DEFAULT '' NOT NULL, |
|
842 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
843 |
ENTRYDATE DATETIME NOT NULL, |
|
844 |
UPDATEDATE DATETIME NOT NULL, |
|
845 |
PRIMARY KEY (JOBCATEGORYCODE) |
|
846 |
); |
|
847 |
|
|
848 |
CREATE TABLE SUBCONTRACTORJOBITEM |
|
849 |
( COMPANYCODE NUMERIC(8,0) NOT NULL, |
|
850 |
ITEMCODE NUMERIC(5,0) NOT NULL, |
|
851 |
DISPLAYORDER NUMERIC(8,0) NOT NULL, |
|
852 |
ENTRYDATE DATETIME NOT NULL, |
|
853 |
UPDATEDATE DATETIME NOT NULL, |
|
854 |
PRIMARY KEY (COMPANYCODE, ITEMCODE) |
|
855 |
); |
|
856 |
|
|
857 |
CREATE TABLE SUBCONTRACTORJOBLINK |
|
858 |
( COMPANYCODE NUMERIC(8,0) NOT NULL, |
|
859 |
JOBCATEGORYCODE NUMERIC(5,0) NOT NULL, |
|
860 |
DISPLAYORDER NUMERIC(8,0) NOT NULL, |
|
861 |
ENTRYDATE DATETIME NOT NULL, |
|
862 |
UPDATEDATE DATETIME NOT NULL, |
|
863 |
PRIMARY KEY (COMPANYCODE, JOBCATEGORYCODE) |
|
864 |
); |
|
865 |
|
|
866 |
CREATE TABLE SUBCONTRACTORMASTER |
|
867 |
( COMPANYCODE NUMERIC(8,0) NOT NULL, |
|
868 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
869 |
CORPORATESTATUSNAME VARCHAR(40) DEFAULT '', |
|
870 |
CORPORATESTATUSPOINT NUMERIC(1,0) NOT NULL, |
|
871 |
COMPANYNAME VARCHAR(100) DEFAULT '' NOT NULL, |
|
872 |
CEOPOSITIONNAME VARCHAR(60) DEFAULT '', |
|
873 |
CEONAME VARCHAR(60) DEFAULT '', |
|
874 |
CONTACTPERSONNAME VARCHAR(60), |
|
875 |
ZIPCODE VARCHAR(8), |
|
876 |
ADDRESS1 VARCHAR(60), |
|
877 |
ADDRESS2 VARCHAR(60) DEFAULT '', |
|
878 |
ADDRESS3 VARCHAR(60), |
|
879 |
CELLPHONENUMBER VARCHAR(13), |
|
880 |
MAILADDRESS VARCHAR(257), |
|
881 |
PHONENUMBER VARCHAR(13) DEFAULT '', |
|
882 |
FAXNUMBER VARCHAR(13) DEFAULT '', |
|
883 |
JAPANESESYLLABARY VARCHAR(2), |
|
884 |
STARTDATE DATE NOT NULL, |
|
885 |
NOTE VARCHAR(300) DEFAULT '', |
|
886 |
LABOURKIND NUMERIC(1,0) NOT NULL, |
|
887 |
DELETEFLG NUMERIC(1,0) DEFAULT 0 NOT NULL, |
|
888 |
ENTRYDATE DATETIME NOT NULL, |
|
889 |
UPDATEDATE DATETIME NOT NULL, |
|
890 |
PRIMARY KEY (COMPANYCODE) |
|
891 |
); |
|
892 |
|
|
893 |
CREATE TABLE SUPPLIERSMASTER |
|
894 |
( SUPPLIERSCODE NUMERIC(5,0) NOT NULL, |
|
895 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
896 |
SUPPLIERSNAME1 VARCHAR(60) DEFAULT '' NOT NULL, |
|
897 |
SUPPLIERSNAME2 VARCHAR(60), |
|
898 |
ZIPCODE VARCHAR(8), |
|
899 |
ADDRESS1 VARCHAR(60), |
|
900 |
ADDRESS2 VARCHAR(60) DEFAULT '', |
|
901 |
ADDRESS3 VARCHAR(60), |
|
902 |
PHONENUMBER VARCHAR(13) DEFAULT '', |
|
903 |
FAXNUMBER VARCHAR(13) DEFAULT '', |
|
904 |
NOTE VARCHAR(300) DEFAULT '', |
|
905 |
DELETEFLG NUMERIC(1,0) NOT NULL, |
|
906 |
ENTRYDATE DATETIME NOT NULL, |
|
907 |
UPDATEDATE DATETIME NOT NULL, |
|
908 |
PRIMARY KEY (SUPPLIERSCODE) |
|
909 |
); |
|
910 |
|
|
911 |
CREATE TABLE SYSTEMEXECUTE |
|
912 |
( PRIMARYCODE NUMERIC(3,0) NOT NULL, |
|
913 |
TARGETDATE DATE NOT NULL, |
|
914 |
ENTRYDATE DATETIME NOT NULL, |
|
915 |
UPDATEDATE DATETIME NOT NULL, |
|
916 |
PRIMARY KEY (PRIMARYCODE) |
|
917 |
); |
|
918 |
|
|
919 |
CREATE TABLE SYSTEMMASTER |
|
920 |
( SYSTEMCODE NUMERIC(3,0) NOT NULL, |
|
921 |
COMPANYNAME1 VARCHAR(60) DEFAULT '' NOT NULL, |
|
922 |
COMPANYNAME2 VARCHAR(60) DEFAULT '', |
|
923 |
CEONAME VARCHAR(60) DEFAULT '' NOT NULL, |
|
924 |
CEOPOSITIONNAME VARCHAR(60) DEFAULT '', |
|
925 |
ZIPCODE VARCHAR(8) NOT NULL, |
|
926 |
ADDRESS1 VARCHAR(60) NOT NULL, |
|
927 |
ADDRESS2 VARCHAR(60) DEFAULT '', |
|
928 |
ADDRESS3 VARCHAR(60), |
|
929 |
PHONENUMBER VARCHAR(13) DEFAULT '' NOT NULL, |
|
930 |
FAXNUMBER VARCHAR(13) DEFAULT '', |
|
931 |
CONSTRUCTIONEXPENSES NUMERIC(4,2) NOT NULL, |
|
932 |
OFFICEEXPENSES NUMERIC(4,2) NOT NULL, |
|
933 |
OPERATINGEXPENSES NUMERIC(4,2) NOT NULL, |
|
934 |
CONSUMPTIONTAX NUMERIC(4,2) NOT NULL, |
|
935 |
EXCELSAVEPATH VARCHAR(120), |
|
936 |
BUSINESSPERIOD NUMERIC(4,0) NOT NULL, |
|
937 |
CONSTRUCTIONYEAR NUMERIC(4,0) NOT NULL, |
|
938 |
BUSINESSBEGINNINGDATE VARCHAR(5) NOT NULL, |
|
939 |
CONSTRUCTIONBEGINNINGDATE VARCHAR(5) NOT NULL, |
|
940 |
CONSTRUCTIONNOBASE NUMERIC(1,0) NOT NULL, |
|
941 |
SLOGANSTRING1 VARCHAR(100), |
|
942 |
SLOGANSTRING2 VARCHAR(100), |
|
943 |
SLOGANSTRING3 VARCHAR(100), |
|
944 |
ENTRYDATE DATETIME NOT NULL, |
|
945 |
UPDATEDATE DATETIME NOT NULL, |
|
946 |
PRIMARY KEY (SYSTEMCODE) |
|
947 |
); |
|
948 |
|
|
949 |
CREATE TABLE TERMMASTER |
|
950 |
( CONSTRUCTIONSTATUSFLG NUMERIC(2,0) NOT NULL, |
|
951 |
FIELDNO NUMERIC(2,0) NOT NULL, |
|
952 |
SEQNO NUMERIC(2,0) NOT NULL, |
|
953 |
DISPLAYORDER NUMERIC(2,0) NOT NULL, |
|
954 |
CHECKSCHDULE NUMERIC(1,0) NOT NULL, |
|
955 |
TERMDAYS NUMERIC(3,0) NOT NULL, |
|
956 |
SENDTITILE VARCHAR(100), |
|
957 |
SENDMESSAGE VARCHAR(100), |
|
958 |
BACKCOLOR VARCHAR(8), |
|
959 |
FORECOLOR VARCHAR(8), |
|
960 |
ENTRYDATE DATETIME NOT NULL, |
|
961 |
UPDATEDATE DATETIME NOT NULL, |
|
962 |
PRIMARY KEY (CONSTRUCTIONSTATUSFLG, FIELDNO, SEQNO) |
|
963 |
); |
|
964 |
|
|
965 |
CREATE TABLE UNITMASTER |
|
966 |
( UNITKEY NUMERIC(5,0) NOT NULL, |
|
967 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
968 |
UNITNAME VARCHAR(30) NOT NULL, |
|
969 |
ENTRYDATE DATETIME NOT NULL, |
|
970 |
UPDATEDATE DATETIME NOT NULL, |
|
971 |
PRIMARY KEY (UNITKEY) |
|
972 |
); |
|
973 |
|
|
974 |
CREATE TABLE VEHICLEMASTER |
|
975 |
( VEHICLECODE NUMERIC(5,0) NOT NULL, |
|
976 |
DISPLAYORDER NUMERIC(5,0) NOT NULL, |
|
977 |
VEHICLENAME VARCHAR(100) NOT NULL, |
|
978 |
REGISTRATIONNUMBER VARCHAR(30), |
|
979 |
IDENTIFICATIONNUMBER VARCHAR(30), |
|
980 |
MODELCODE VARCHAR(30), |
|
981 |
DEPARTMENTCODE NUMERIC(5,0) NOT NULL, |
|
982 |
VEHICLESCHEDULEFLG NUMERIC(1,0) NOT NULL, |
|
983 |
PURCHASEDATE DATE, |
|
984 |
PURCHASENAME VARCHAR(30), |
|
985 |
PURCHASECONTACTPERSONS VARCHAR(30), |
|
986 |
PURCHASEPHONE VARCHAR(13), |
|
987 |
LEASEDATE DATE, |
|
988 |
LEASEDESTINATION VARCHAR(30), |
|
989 |
LEASECONTACTPERSONS VARCHAR(30), |
|
990 |
LEASEPHONE VARCHAR(13), |
|
991 |
INSURANCECOMPANY VARCHAR(30), |
|
992 |
INSURANCECONTACTPERSONS VARCHAR(30), |
|
993 |
INSURANCEPHONE VARCHAR(13), |
|
994 |
NOTE VARCHAR(300), |
|
995 |
ENTRYDATE DATETIME, |
|
996 |
UPDATEDATE DATETIME, |
|
997 |
PRIMARY KEY (VEHICLECODE) |
|
998 |
); |
|
999 |
|
|
1000 |
CREATE TABLE VEHICLERECORDDATA |
|
1001 |
( VEHICLECODE NUMERIC(5,0) NOT NULL, |
|
1002 |
DIVISIONCODE NUMERIC(2,0) NOT NULL, |
|
1003 |
SEQNO NUMERIC(3,0) NOT NULL, |
|
1004 |
RECORDDATE DATE, |
|
1005 |
MILEAGE NUMERIC(7,0), |
|
1006 |
CONTENT VARCHAR(100), |
|
1007 |
PAYMENTCOST NUMERIC(10,2), |
|
1008 |
ENTRYDATE DATETIME NOT NULL, |
|
1009 |
UPDATEDATE DATETIME NOT NULL, |
|
1010 |
PRIMARY KEY (VEHICLECODE, DIVISIONCODE, SEQNO) |
|
1011 |
); |
|
1012 |
|
|
1013 |
CREATE TABLE VEHICLESCHEDULEDATA |
|
1014 |
( TARGETDATE DATE NOT NULL, |
|
1015 |
VEHICLECODE NUMERIC(5,0) NOT NULL, |
|
1016 |
MORNINGAFTERNOON NUMERIC(1,0) NOT NULL, |
|
1017 |
PERSONCODE NUMERIC(8,0) NOT NULL, |
|
1018 |
TARGETYEAR NUMERIC(4,0) NOT NULL, |
|
1019 |
TARGETMONTH NUMERIC(2,0) NOT NULL, |
|
1020 |
TARGETDAY NUMERIC(2,0) NOT NULL, |
|
1021 |
ENTRYDATE DATETIME NOT NULL, |
|
1022 |
UPDATEDATE DATETIME NOT NULL, |
|
1023 |
PRIMARY KEY (TARGETDATE, VEHICLECODE, MORNINGAFTERNOON) |
|
1024 |
); |
|
1025 |
|
他の形式にエクスポート: Unified diff