File: gdpdm.ddl

package info (click to toggle)
libsql-translator-perl 0.11011-1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 15,380 kB
  • sloc: perl: 251,748; sql: 3,805; xml: 233; makefile: 7
file content (316 lines) | stat: -rw-r--r-- 6,721 bytes parent folder | download | duplicates (10)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
DROP TABLE div_aa_annotation;
CREATE TABLE div_aa_annotation
 (
	div_aa_annotation_id			Long Integer (4), 
	div_annotation_type_id			Long Integer (4), 
	div_allele_assay_id			Long Integer (4), 
	annotation_value			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_allele;
CREATE TABLE div_allele
 (
	div_allele_id			Long Integer (4), 
	div_obs_unit_sample_id			Long Integer (4), 
	div_allele_assay_id			Long Integer (4), 
	allele_num			Long Integer (4), 
	quality			Long Integer (4), 
	value			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_allele_assay;
CREATE TABLE div_allele_assay
 (
	div_allele_assay_id			Long Integer (4), 
	div_marker_id			Long Integer (4), 
	div_poly_type_id			Long Integer (4), 
	comments			Text (50), 
	date			DateTime (Short) (8), 
	name			Text (50), 
	phase_determined			Text (50), 
	producer			Text (50), 
	position			Text (50), 
	ref_seq			Text (50), 
	div_ref_stock_id			Long Integer (4), 
	source_assay			Text (50), 
	length			Long Integer (4)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_annotation_type;
CREATE TABLE div_annotation_type
 (
	div_annotation_type_id			Long Integer (4), 
	anno_type			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_exp_entry;
CREATE TABLE div_exp_entry
 (
	div_exp_entry_id			Long Integer (4), 
	div_experiment_id			Long Integer (4), 
	div_obsunit_id			Long Integer (4), 
	div_stock_id			Long Integer (4), 
	plant			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_experiment;
CREATE TABLE div_experiment
 (
	div_experiment_id			Long Integer (4), 
	name			Text (50), 
	design			Text (50), 
	originator			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_generation;
CREATE TABLE div_generation
 (
	div_generation_id			Long Integer (4), 
	value			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_locality;
CREATE TABLE div_locality
 (
	div_locality_id			Long Integer (4), 
	elevation			Long Integer (4), 
	city			Text (50), 
	country			Text (50), 
	origcty			Text (50), 
	latitude			Long Integer (4), 
	longitude			Long Integer (4), 
	locality_name			Text (50), 
	state_province			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_locus;
CREATE TABLE div_locus
 (
	div_locus_id			Long Integer (4), 
	chromosome_number			Long Integer (4), 
	comments			Text (50), 
	genetic_bin			Text (50), 
	genetic_map			Text (50), 
	genetic_position			Long Integer (4), 
	locus_type			Text (50), 
	name			Text (50), 
	physical_position			Long Integer (4)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_marker;
CREATE TABLE div_marker
 (
	div_marker_id			Long Integer (4), 
	div_locus_id			Long Integer (4), 
	name			Text (50), 
	ref_seq			Text (50), 
	div_ref_stock_id			Long Integer (4)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_obs_unit;
CREATE TABLE div_obs_unit
 (
	div_obs_unit_id			Long Integer (4), 
	div_experiment_id			Long Integer (4), 
	div_stock_id			Long Integer (4), 
	div_locality_id			Long Integer (4), 
	name			Text (50), 
	field_coord_x			Long Integer (4), 
	field_coord_y			Long Integer (4), 
	rep			Long Integer (4), 
	block			Long Integer (4), 
	plot			Long Integer (4), 
	plant			Text (50), 
	planting_date			DateTime (Short) (8), 
	harvest_date			DateTime (Short) (8), 
	summary			Boolean

);
-- CREATE ANY INDEXES ...

DROP TABLE div_obs_unit_sample;
CREATE TABLE div_obs_unit_sample
 (
	div_obs_unit_sample_id			Long Integer (4), 
	div_obs_unit_id			Long Integer (4), 
	date			DateTime (Short) (8), 
	name			Text (50), 
	producer			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_passport;
CREATE TABLE div_passport
 (
	div_passport_id			Long Integer (4), 
	div_locality_id			Long Integer (4), 
	accename			Text (50), 
	collnumb			Long Integer (4), 
	collector			Text (50), 
	remarks			Text (50), 
	genus			Text (50), 
	germplasm_type			Text (50), 
	local_name			Text (50), 
	population			Text (50), 
	race_name			Text (50), 
	reference			Text (50), 
	secondary_source			Text (50), 
	source			Text (50), 
	species			Text (50), 
	subspecies			Text (50), 
	instcode			Text (50), 
	accenumb			Long Integer (4), 
	collcode			Text (50), 
	spauthor			Text (50), 
	subtaxa			Text (50), 
	subtauthor			Text (50), 
	cropname			Text (50), 
	acqdate			DateTime (Short) (8), 
	colldate			DateTime (Short) (8), 
	bredcode			Text (50), 
	sampstat			Text (50), 
	collsrc			Text (50), 
	donorcode			Text (50), 
	donornumb			Long Integer (4), 
	othernumb			Long Integer (4), 
	duplsite			Text (50), 
	storage			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_poly_type;
CREATE TABLE div_poly_type
 (
	div_poly_type_id			Long Integer (4), 
	poly_type			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_statistic_type;
CREATE TABLE div_statistic_type
 (
	div_statistic_type_id			Long Integer (4), 
	stat_type			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_stock;
CREATE TABLE div_stock
 (
	div_stock_id			Long Integer (4), 
	div_generation_id			Long Integer (4), 
	div_passport_id			Long Integer (4), 
	seed_lot			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_stock_parent;
CREATE TABLE div_stock_parent
 (
	div_stock_parent_id			Long Integer (4), 
	div_stock_id			Long Integer (4), 
	div_parent_id			Long Integer (4), 
	recurrent			Boolean, 
	role			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_trait;
CREATE TABLE div_trait
 (
	div_trait_id			Long Integer (4), 
	div_trait_uom_id			Long Integer (4), 
	div_statistic_type_id			Long Integer (4), 
	div_obs_unit_id			Long Integer (4), 
	date			DateTime (Short) (8), 
	value			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_trait_uom;
CREATE TABLE div_trait_uom
 (
	div_trait_uom_id			Long Integer (4), 
	qtl_trait_ontology_id			Long Integer (4), 
	div_unit_of_measure_id			Long Integer (4), 
	local_trait_name			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_treatment;
CREATE TABLE div_treatment
 (
	div_treatment_id			Long Integer (4), 
	div_treatment_uom_id			Long Integer (4), 
	div_obs_unit_id			Long Integer (4), 
	value			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_treatment_uom;
CREATE TABLE div_treatment_uom
 (
	div_treatment_uom_id			Long Integer (4), 
	qtl_treatment_ontology_id			Long Integer (4), 
	div_unit_of_measure_id			Long Integer (4)

);
-- CREATE ANY INDEXES ...

DROP TABLE div_unit_of_measure;
CREATE TABLE div_unit_of_measure
 (
	div_unit_of_measure_id			Long Integer (4), 
	unit_type			Text (50)

);
-- CREATE ANY INDEXES ...

DROP TABLE qtl_trait_ontology;
CREATE TABLE qtl_trait_ontology
 (
	qtl_trait_ontology_id			Long Integer (4)

);
-- CREATE ANY INDEXES ...

DROP TABLE qtl_treatment_ontology;
CREATE TABLE qtl_treatment_ontology
 (
	qtl_treatment_ontology_id			Long Integer (4)

);
-- CREATE ANY INDEXES ...



-- CREATE ANY Relationships ...