| ... |
... |
@@ -27,35 +27,7 @@ CREATE TABLE ps_observation.nontargetcatchreleaseconformity(topiaid VARCHAR(255) |
|
27
|
27
|
CREATE TABLE ps_observation.nontargetcatchreleasestatus(topiaid VARCHAR(255) NOT NULL CONSTRAINT pk_ps_observation_nontargetcatchreleasestatus PRIMARY KEY, topiaversion BIGINT NOT NULL, topiacreatedate DATE, lastupdatedate TIMESTAMP NOT NULL, code VARCHAR(255), status INTEGER DEFAULT 1, needcomment BOOLEAN DEFAULT FALSE, uri VARCHAR(255), label1 VARCHAR(255), label2 VARCHAR(255), label3 VARCHAR(255), label4 VARCHAR(255), label5 VARCHAR(255), label6 VARCHAR(255), label7 VARCHAR(255), label8 VARCHAR(255));
|
|
28
|
28
|
CREATE TABLE ps_observation.nontargetcatchreleasingtime(topiaid VARCHAR(255) NOT NULL CONSTRAINT pk_ps_observation_nontargetcatchreleasingtime PRIMARY KEY, topiaversion BIGINT NOT NULL, topiacreatedate DATE, lastupdatedate TIMESTAMP NOT NULL, code VARCHAR(255), status INTEGER DEFAULT 1, needcomment BOOLEAN DEFAULT FALSE, uri VARCHAR(255), label1 VARCHAR(255), label2 VARCHAR(255), label3 VARCHAR(255), label4 VARCHAR(255), label5 VARCHAR(255), label6 VARCHAR(255), label7 VARCHAR(255), label8 VARCHAR(255));
|
|
29
|
29
|
CREATE TABLE ps_observation.objectmaterialtype(topiaid VARCHAR(255) NOT NULL CONSTRAINT pk_ps_observation_object_material_type PRIMARY KEY, topiaversion BIGINT NOT NULL, topiacreatedate DATE, lastupdatedate TIMESTAMP NOT NULL, code VARCHAR(255) NOT NULL, status INTEGER DEFAULT 1, needcomment BOOLEAN DEFAULT FALSE, uri VARCHAR(255), label1 VARCHAR(255), label2 VARCHAR(255), label3 VARCHAR(255), label4 VARCHAR(255), label5 VARCHAR(255), label6 VARCHAR(255), label7 VARCHAR(255), label8 VARCHAR(255));
|
|
30
|
|
-CREATE TABLE ps_observation.objectmaterial
|
|
31
|
|
-(
|
|
32
|
|
- topiaid VARCHAR(255) NOT NULL
|
|
33
|
|
- CONSTRAINT pk_ps_observation_object_material PRIMARY KEY,
|
|
34
|
|
- topiaversion BIGINT NOT NULL,
|
|
35
|
|
- topiacreatedate DATE,
|
|
36
|
|
- lastupdatedate TIMESTAMP NOT NULL,
|
|
37
|
|
- code VARCHAR(255) NOT NULL,
|
|
38
|
|
- legacycode VARCHAR(1025),
|
|
39
|
|
- standardcode VARCHAR(255),
|
|
40
|
|
- parent VARCHAR(255),
|
|
41
|
|
- status INTEGER DEFAULT 1,
|
|
42
|
|
- needcomment BOOLEAN DEFAULT FALSE,
|
|
43
|
|
- uri VARCHAR(255),
|
|
44
|
|
- objectmaterialtype VARCHAR(255),
|
|
45
|
|
- biodegradable BOOLEAN,
|
|
46
|
|
- nonentangling BOOLEAN,
|
|
47
|
|
- label1 VARCHAR(255),
|
|
48
|
|
- label2 VARCHAR(255),
|
|
49
|
|
- label3 VARCHAR(255),
|
|
50
|
|
- label4 VARCHAR(255),
|
|
51
|
|
- label5 VARCHAR(255),
|
|
52
|
|
- label6 VARCHAR(255),
|
|
53
|
|
- label7 VARCHAR(255),
|
|
54
|
|
- label8 VARCHAR(255),
|
|
55
|
|
- childrenmultiselectable BOOLEAN,
|
|
56
|
|
- childselectionmandatory BOOLEAN,
|
|
57
|
|
- validation VARCHAR(255)
|
|
58
|
|
-);
|
|
|
30
|
+CREATE TABLE ps_observation.objectmaterial(topiaid VARCHAR(255) NOT NULL CONSTRAINT pk_ps_observation_object_material PRIMARY KEY,topiaversion BIGINT NOT NULL,topiacreatedate DATE,lastupdatedate TIMESTAMP NOT NULL,code VARCHAR(255) NOT NULL,legacycode VARCHAR(1025),standardcode VARCHAR(255),parent VARCHAR(255),status INTEGER DEFAULT 1,needcomment BOOLEAN DEFAULT FALSE,uri VARCHAR(255),objectmaterialtype VARCHAR(255),biodegradable BOOLEAN,nonentangling BOOLEAN,label1 VARCHAR(255),label2 VARCHAR(255),label3 VARCHAR(255),label4 VARCHAR(255),label5 VARCHAR(255),label6 VARCHAR(255),label7 VARCHAR(255),label8 VARCHAR(255),childrenmultiselectable BOOLEAN,childselectionmandatory BOOLEAN,validation VARCHAR(255));
|
|
59
|
31
|
CREATE TABLE ps_observation.objectoperation(topiaid VARCHAR(255) NOT NULL CONSTRAINT pk_ps_observation_objectoperation PRIMARY KEY, topiaversion BIGINT NOT NULL, topiacreatedate TIMESTAMP, code VARCHAR(255), uri VARCHAR(255), status INTEGER DEFAULT 1, label1 VARCHAR(255), label2 VARCHAR(255), label3 VARCHAR(255), label4 VARCHAR(255), label5 VARCHAR(255), label6 VARCHAR(255), label7 VARCHAR(255), label8 VARCHAR(255), needcomment BOOLEAN DEFAULT FALSE, lastupdatedate TIMESTAMP DEFAULT now() NOT NULL, whenarriving BOOLEAN DEFAULT TRUE, whenleaving BOOLEAN DEFAULT TRUE);
|
|
60
|
32
|
CREATE TABLE ps_observation.observedsystem(topiaid VARCHAR(255) NOT NULL CONSTRAINT pk_ps_observation_observedsystem PRIMARY KEY, topiaversion BIGINT NOT NULL, topiacreatedate TIMESTAMP, code VARCHAR(255), needcomment BOOLEAN, uri VARCHAR(255), status INTEGER DEFAULT 1, label1 VARCHAR(255), label2 VARCHAR(255), label3 VARCHAR(255), label4 VARCHAR(255), label5 VARCHAR(255), label6 VARCHAR(255), label7 VARCHAR(255), label8 VARCHAR(255), schooltype INTEGER, lastupdatedate TIMESTAMP DEFAULT now() NOT NULL);
|
|
61
|
33
|
CREATE TABLE ps_observation.reasonfordiscard(topiaid VARCHAR(255) NOT NULL CONSTRAINT pk_ps_observation_reasonfordiscard PRIMARY KEY, topiaversion BIGINT NOT NULL, topiacreatedate TIMESTAMP, code VARCHAR(255), needcomment BOOLEAN, uri VARCHAR(255), status INTEGER DEFAULT 1, label1 VARCHAR(255), label2 VARCHAR(255), label3 VARCHAR(255), label4 VARCHAR(255), label5 VARCHAR(255), label6 VARCHAR(255), label7 VARCHAR(255), label8 VARCHAR(255), lastupdatedate TIMESTAMP DEFAULT now() NOT NULL);
|
| ... |
... |
@@ -88,36 +60,7 @@ INSERT INTO ps_observation.nontargetcatchreleaseconformity(topiaid, topiaversion |
|
88
|
60
|
INSERT INTO ps_observation.nontargetcatchreleasestatus(topiaid, topiaversion, topiacreatedate, lastupdatedate, code, status, needcomment, uri, label1, label2, label3, label4, label5, label6, label7, label8) SELECT topiaid, topiaversion, topiacreatedate, lastupdatedate, code, status, needcomment, uri, label1, label2, label3, label4, label5, label6, label7, label8 FROM observe_seine.nontargetcatchreleasestatus;
|
|
89
|
61
|
INSERT INTO ps_observation.nontargetcatchreleasingtime(topiaid, topiaversion, topiacreatedate, lastupdatedate, code, status, needcomment, uri, label1, label2, label3, label4, label5, label6, label7, label8) SELECT topiaid, topiaversion, topiacreatedate, lastupdatedate, code, status, needcomment, uri, label1, label2, label3, label4, label5, label6, label7, label8 FROM observe_seine.nontargetcatchreleasingtime;
|
|
90
|
62
|
INSERT INTO ps_observation.objectmaterialtype(topiaid, topiaversion, topiacreatedate, lastupdatedate, code, status, needcomment, uri, label1, label2, label3, label4, label5, label6, label7, label8) SELECT topiaid, topiaversion, topiacreatedate, lastupdatedate, code, status, needcomment, uri, label1, label2, label3, label4, label5, label6, label7, label8 FROM observe_seine.objectmaterialtype;
|
|
91
|
|
-INSERT INTO ps_observation.objectmaterial(topiaid, topiaversion, topiacreatedate, lastupdatedate, code, legacycode,
|
|
92
|
|
- standardcode, parent, status, needcomment, uri, objectmaterialtype,
|
|
93
|
|
- biodegradable, nonentangling, label1, label2, label3, label4, label5, label6,
|
|
94
|
|
- label7, label8, childrenmultiselectable, childselectionmandatory, validation)
|
|
95
|
|
-SELECT topiaid,
|
|
96
|
|
- topiaversion,
|
|
97
|
|
- topiacreatedate,
|
|
98
|
|
- lastupdatedate,
|
|
99
|
|
- code,
|
|
100
|
|
- legacycode,
|
|
101
|
|
- standardcode,
|
|
102
|
|
- parent,
|
|
103
|
|
- status,
|
|
104
|
|
- needcomment,
|
|
105
|
|
- uri,
|
|
106
|
|
- objectmaterialtype,
|
|
107
|
|
- biodegradable,
|
|
108
|
|
- nonentangling,
|
|
109
|
|
- label1,
|
|
110
|
|
- label2,
|
|
111
|
|
- label3,
|
|
112
|
|
- label4,
|
|
113
|
|
- label5,
|
|
114
|
|
- label6,
|
|
115
|
|
- label7,
|
|
116
|
|
- label8,
|
|
117
|
|
- childrenmultiselectable,
|
|
118
|
|
- childselectionmandatory,
|
|
119
|
|
- validation
|
|
120
|
|
-FROM observe_seine.objectmaterial;
|
|
|
63
|
+INSERT INTO ps_observation.objectmaterial(topiaid, topiaversion, topiacreatedate, lastupdatedate, code, legacycode, standardcode, parent, status, needcomment, uri, objectmaterialtype, biodegradable, nonentangling, label1, label2, label3, label4, label5, label6, label7, label8, childrenmultiselectable, childselectionmandatory, validation) SELECT topiaid,topiaversion,topiacreatedate,lastupdatedate,code,legacycode,standardcode,parent,status,needcomment,uri,objectmaterialtype,biodegradable,nonentangling,label1,label2,label3,label4,label5,label6,label7,label8,childrenmultiselectable,childselectionmandatory,validation FROM observe_seine.objectmaterial;
|
|
121
|
64
|
INSERT INTO ps_observation.objectoperation(topiaid, topiaversion, topiacreatedate, code, uri, status, label1, label2, label3, label4, label5, label6, label7, label8, needcomment, lastupdatedate, whenarriving, whenleaving) SELECT topiaid, topiaversion, topiacreatedate, code, uri, status, label1, label2, label3, label4, label5, label6, label7, label8, needcomment, lastupdatedate, whenarriving, whenleaving FROM observe_seine.objectoperation;
|
|
122
|
65
|
INSERT INTO ps_observation.observedsystem(topiaid, topiaversion, topiacreatedate, code, needcomment, uri, status, label1, label2, label3, label4, label5, label6, label7, label8, schooltype, lastupdatedate) SELECT topiaid, topiaversion, topiacreatedate, code, needcomment, uri, status, label1, label2, label3, label4, label5, label6, label7, label8, schooltype, lastupdatedate FROM observe_seine.observedsystem;
|
|
123
|
66
|
INSERT INTO ps_observation.reasonfordiscard(topiaid, topiaversion, topiacreatedate, code, needcomment, uri, status, label1, label2, label3, label4, label5, label6, label7, label8, lastupdatedate) SELECT topiaid, topiaversion, topiacreatedate, code, needcomment, uri, status, label1, label2, label3, label4, label5, label6, label7, label8, lastupdatedate FROM observe_seine.reasonfordiscard;
|