source: ether_statistics/persistence/sql/vmipsl_createMCO.sql @ 569

Last change on this file since 569 was 569, checked in by vmipsl, 12 years ago

Nouveau projet

File size: 3.3 KB
Line 
1CREATE SEQUENCE S_MCO
2/* GO */
3
4
5/*==============================================================*/
6/* Table : USER                                                 */
7/*==============================================================*/
8CREATE TABLE MCO  (
9   MCO_ID                 NUMBER(9,0)               NOT NULL,
10   CODE               NVARCHAR2(20),
11   CREATION_DATE      TIMESTAMP                 NOT NULL,
12   CLOSING_DATE       TIMESTAMP,
13   EMAIL_USER             NVARCHAR2(100)                        NOT NULL,
14   TITLE              NVARCHAR2(100),
15   STATE                      NVARCHAR2(20)                         NOT NULL,
16   TYPE               NVARCHAR2(20)                         NOT NULL,
17   INFORMATIONS       NVARCHAR2(1000),
18
19   CONSTRAINT PK_MCO PRIMARY KEY (MCO_ID)
20)
21/* GO */
22
23
24COMMENT ON TABLE MCO IS
25'This table contents all the requests from user'
26/* GO */
27
28
29COMMENT ON COLUMN MCO.MCO_ID IS 'The identifier of the mco request'
30/* GO */
31
32COMMENT ON COLUMN MCO.CODE IS 'The code of the mco request'
33/* GO */
34
35COMMENT ON COLUMN MCO.CREATION_DATE IS 'The creation date of the request. It never changes even the state will be modified'
36/* GO */
37
38COMMENT ON COLUMN MCO.CLOSING_DATE IS 'The closing date of the request'
39/* GO */
40
41COMMENT ON COLUMN MCO.EMAIL_USER IS 'The email of the user'
42/* GO */
43
44COMMENT ON COLUMN MCO.TITLE IS 'The title of the request'
45/* GO */
46
47COMMENT ON COLUMN MCO.STATE IS 'The state of the request. Examples : open, close, in work, ...'
48/* GO */
49
50COMMENT ON COLUMN MCO.TYPE IS 'The type of the request. Examples : new_account, problem, ...'
51/* GO */
52
53COMMENT ON COLUMN MCO.INFORMATIONS IS 'The content of the request, email s users, answers, ...'
54/* GO */
55
56
57/*==============================================================*/
58/* VERSION POSTGRES                                             */
59/*==============================================================*/
60CREATE TABLE "public"."MCO" (
61"MCO_ID" int4 DEFAULT NULL NOT NULL,
62"CODE" varchar(20) DEFAULT NULL,
63"CREATION_DATE" timestamp(6) DEFAULT NULL NOT NULL,
64"CLOSING_DATE" timestamp(6) DEFAULT NULL,
65"EMAIL_USER" varchar(100) DEFAULT NULL NOT NULL,
66"TITLE" varchar(100) DEFAULT NULL,
67"STATE" varchar(20) DEFAULT NULL NOT NULL,
68"TYPE" varchar(20) DEFAULT NULL NOT NULL,
69"INFORMATIONS" varchar(1000) DEFAULT NULL,
70CONSTRAINT "MCO_pkey" PRIMARY KEY ("MCO_ID")
71)
72WITH (OIDS=FALSE)
73;
74
75ALTER TABLE "public"."MCO" OWNER TO "postgres";
76
77COMMENT ON TABLE "public"."MCO" IS 'This table contents all the requests from user';
78
79COMMENT ON COLUMN "public"."MCO"."MCO_ID" IS 'The identifier of the mco request';
80
81COMMENT ON COLUMN "public"."MCO"."CODE" IS 'The code of the mco request';
82
83COMMENT ON COLUMN "public"."MCO"."CREATION_DATE" IS 'The creation date of the request. It never changes even the state will be modified';
84
85COMMENT ON COLUMN "public"."MCO"."CLOSING_DATE" IS 'The closing date of the request';
86
87COMMENT ON COLUMN "public"."MCO"."EMAIL_USER" IS 'The email of the user';
88
89COMMENT ON COLUMN "public"."MCO"."TITLE" IS 'The title of the request';
90
91COMMENT ON COLUMN "public"."MCO"."STATE" IS 'The state of the request. Examples : open, close, in work, ...';
92
93COMMENT ON COLUMN "public"."MCO"."TYPE" IS 'The type of the request. Examples : new_account, problem, ...';
94
95COMMENT ON COLUMN "public"."MCO"."INFORMATIONS" IS 'The content of the request, email s users, answers, ...';
Note: See TracBrowser for help on using the repository browser.