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
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
|
/*
SOYUZ SAMPLE DATA
Copyright 2009 Canonical Ltd. This software is licensed under the
GNU Affero General Public License version 3 (see the file LICENSE).
This is some sample data for the Soyuz App components.
This requires the default data to be inserted first.
*/
/*
Sample data for Soyuz
*/
-- Component
INSERT INTO Component (name) VALUES ('main');
INSERT INTO Component (name) VALUES ('restricted');
INSERT INTO Component (name) VALUES ('universe');
-- Section
INSERT INTO Section (name) VALUES ('base');
INSERT INTO Section (name) VALUES ('web');
INSERT INTO Section (name) VALUES ('editors');
INSERT INTO Section (name) VALUES ('admin');
INSERT INTO Section (name) VALUES ('comm');
INSERT INTO Section (name) VALUES ('debian-installer');
INSERT INTO Section (name) VALUES ('devel');
INSERT INTO Section (name) VALUES ('doc');
INSERT INTO Section (name) VALUES ('games');
INSERT INTO Section (name) VALUES ('gnome');
INSERT INTO Section (name) VALUES ('graphics');
INSERT INTO Section (name) VALUES ('interpreters');
INSERT INTO Section (name) VALUES ('kde');
INSERT INTO Section (name) VALUES ('libdevel');
INSERT INTO Section (name) VALUES ('libs');
INSERT INTO Section (name) VALUES ('mail');
INSERT INTO Section (name) VALUES ('math');
INSERT INTO Section (name) VALUES ('misc');
INSERT INTO Section (name) VALUES ('net');
INSERT INTO Section (name) VALUES ('news');
INSERT INTO Section (name) VALUES ('oldlibs');
INSERT INTO Section (name) VALUES ('otherosfs');
INSERT INTO Section (name) VALUES ('perl');
INSERT INTO Section (name) VALUES ('python');
INSERT INTO Section (name) VALUES ('shells');
INSERT INTO Section (name) VALUES ('sound');
INSERT INTO Section (name) VALUES ('tex');
INSERT INTO Section (name) VALUES ('text');
INSERT INTO Section (name) VALUES ('translations');
INSERT INTO Section (name) VALUES ('utils');
INSERT INTO Section (name) VALUES ('x11');
INSERT INTO Section (name) VALUES ('electronics');
INSERT INTO Section (name) VALUES ('embedded');
INSERT INTO Section (name) VALUES ('hamradio');
INSERT INTO Section (name) VALUES ('science');
-- Schema
INSERT INTO schema (name, title, description, owner, extensible) VALUES
('Mark schema', 'TITLE', 'description',
(SELECT id FROM Person WHERE displayname = 'Mark Shuttleworth'),
TRUE);
INSERT INTO Schema (name, title, description, owner, extensible) VALUES
('schema', 'SCHEMA', 'description',
(SELECT id FROM Person WHERE displayname = 'Mark Shuttleworth'),
TRUE);
INSERT INTO Schema (name, title, description, owner, extensible) VALUES
('trema', 'XCHEMA', 'description',
(SELECT id FROM Person WHERE displayname = 'Mark Shuttleworth'),
TRUE);
INSERT INTO Schema (name, title, description, owner, extensible) VALUES
('enema', 'ENHEMA', 'description',
(SELECT id FROM Person WHERE displayname = 'Mark Shuttleworth'),
TRUE);
--Manifest
INSERT INTO Manifest (datecreated, owner)
VALUES (timestamp '2004-06-29 00:00',
(SELECT id FROM Person WHERE displayname = 'Mark Shuttleworth')
);
INSERT INTO Manifest (datecreated, owner)
VALUES (timestamp '2004-06-30 00:00',
(SELECT id FROM Person WHERE displayname = 'Steve Alexander')
);
INSERT INTO Manifest (datecreated, owner)
VALUES (timestamp '2004-07-01 00:00',
(SELECT id FROM Person WHERE displayname = 'Andrew Bennetts')
);
INSERT INTO Manifest (datecreated, owner)
VALUES (timestamp '2004-07-02 00:00',
(SELECT id FROM Person WHERE displayname = 'Dave Miller')
);
INSERT INTO Manifest (datecreated, owner)
VALUES (timestamp '2004-07-03 00:00',
(SELECT id FROM Person WHERE displayname = 'James Blackwell')
);
INSERT INTO Manifest (datecreated, owner)
VALUES (timestamp '2004-07-04 00:00',
(SELECT id FROM Person WHERE displayname = 'Christian Reis')
);
INSERT INTO Manifest (datecreated, owner)
VALUES (timestamp '2004-07-05 00:00',
(SELECT id FROM Person WHERE displayname = 'Alexander Limi')
);
/*
--CodeRelease
INSERT INTO CodeRelease (sourcepackagerelease, manifest)
VALUES ((SELECT id FROM SourcePackageRelease WHERE
dateuploaded = timestamp '2004-06-29 00:00'),
(SELECT id FROM Manifest WHERE datecreated = timestamp '2004-06-29 00:00'));
INSERT INTO CodeRelease (sourcepackagerelease, manifest)
VALUES ((SELECT id FROM SourcePackageRelease WHERE
dateuploaded = timestamp '2004-06-30 00:00'),
(SELECT id FROM Manifest WHERE datecreated = timestamp '2004-06-30 00:00'));
INSERT INTO CodeRelease (sourcepackagerelease, manifest)
VALUES ((SELECT id FROM SourcePackageRelease WHERE
dateuploaded = timestamp '2004-07-01 00:00'),
(SELECT id FROM Manifest WHERE datecreated = timestamp '2004-07-01 00:00'));
INSERT INTO CodeRelease (sourcepackagerelease, manifest)
VALUES ((SELECT id FROM SourcePackageRelease WHERE
dateuploaded = timestamp '2004-07-02 00:00'),
(SELECT id FROM Manifest WHERE datecreated = timestamp '2004-07-02 00:00'));
INSERT INTO CodeRelease (sourcepackagerelease, manifest)
VALUES ((SELECT id FROM SourcePackageRelease WHERE
dateuploaded = timestamp '2004-07-03 00:00'),
(SELECT id FROM Manifest WHERE datecreated = timestamp '2004-07-03 00:00'));
INSERT INTO CodeRelease (sourcepackagerelease, manifest)
VALUES ((SELECT id FROM SourcePackageRelease WHERE
dateuploaded = timestamp '2004-07-04 00:00'),
(SELECT id FROM Manifest WHERE datecreated = timestamp '2004-07-04 00:00'));
INSERT INTO CodeRelease (sourcepackagerelease, manifest)
VALUES ((SELECT id FROM SourcePackageRelease WHERE
dateuploaded = timestamp '2004-07-05 00:00'),
(SELECT id FROM Manifest WHERE datecreated = timestamp '2004-06-29 00:00'));
--ArchArchive
INSERT INTO ArchArchive (name, title, description, visible)
VALUES ('mozilla', 'Mozilla', 'text', false);
INSERT INTO ArchArchive (name, title, description, visible)
VALUES ('thunderbird', 'Thunderbid', 'text', false);
INSERT INTO ArchArchive (name, title, description, visible)
VALUES ('twisted', 'Twisted', 'text', false);
INSERT INTO ArchArchive (name, title, description, visible)
VALUES ('bugzila', 'Bugzila', 'text', false);
INSERT INTO ArchArchive (name, title, description, visible)
VALUES ('arch', 'Arch', 'text', false);
INSERT INTO ArchArchive (name, title, description, visible)
VALUES ('kiwi2', 'Kiwi2', 'text', false);
INSERT INTO ArchArchive (name, title, description, visible)
VALUES ('plone', 'Plone', 'text', false);
--Archnamespace
INSERT INTO Archnamespace (archarchive, category, visible)
VALUES (1, 'mozilla', true);
INSERT INTO Archnamespace (archarchive, category, visible)
VALUES (2, 'tunderbird', true);
INSERT INTO Archnamespace (archarchive, category, visible)
VALUES (3, 'twisted', true);
INSERT INTO Archnamespace (archarchive, category, visible)
VALUES (4, 'bugzila', true);
INSERT INTO Archnamespace (archarchive, category, visible)
VALUES (5, 'arch', true);
INSERT INTO Archnamespace (archarchive, category, visible)
VALUES (6, 'kiwi2', true);
INSERT INTO Archnamespace (archarchive, category, visible)
VALUES (7, 'plone', true);
--Branch
INSERT INTO Branch (archnamespace, title, description, owner)
VALUES ((SELECT id FROM ArchArchive WHERE name = 'mozilla'),
'Mozilla Firefox 0.9.1', 'text',
(SELECT id FROM Person WHERE displayname = 'Mark Shuttleworth'));
INSERT INTO Branch (archnamespace, title, description, owner)
VALUES ((SELECT id FROM ArchArchive WHERE name = 'thunderbird'),
'Mozilla Thunderbird 0.9.1', 'text',
(SELECT id FROM Person WHERE displayname = 'Steve Alexander'));
INSERT INTO Branch (archnamespace, title, description, owner)
VALUES ((SELECT id FROM ArchArchive WHERE name = 'twisted'),
'Python Twisted 0.9.1', 'text',
(SELECT id FROM Person WHERE displayname = 'Andrew Bennetts'));
INSERT INTO Branch (archnamespace, title, description, owner)
VALUES ((SELECT id FROM ArchArchive WHERE name = 'bugzila'),
'Bugzila 0.9.1', 'text',
(SELECT id FROM Person WHERE displayname = 'Dave Miller'));
INSERT INTO Branch (archnamespace, title, description, owner)
VALUES ((SELECT id FROM ArchArchive WHERE name = 'arch'),
'Arch 0.9.1', 'text',
(SELECT id FROM Person WHERE displayname = 'James Blackwell'));
INSERT INTO Branch (archnamespace, title, description, owner)
VALUES ((SELECT id FROM ArchArchive WHERE name = 'kiwi2'),
'Kiwi2 0.9.1', 'text',
(SELECT id FROM Person WHERE displayname = 'Christian Reis'));
INSERT INTO Branch (archnamespace, title, description, owner)
VALUES ((SELECT id FROM ArchArchive WHERE name = 'plone'),
'Plone 0.9.1', 'text',
(SELECT id FROM Person WHERE displayname = 'Alexander Limi'));
*/
-- Label
INSERT INTO Label (schema, name, title, description)
VALUES ((SELECT id FROM Schema WHERE name = 'Mark schema'),
'blah', 'blah', 'blah');
-- ProcessorFamily
INSERT INTO ProcessorFamily (name, title, description, owner)
VALUES ('x86', 'Intel 386 compatible chips', 'Bring back the 8086!',
(SELECT id FROM Person WHERE displayname = 'Mark Shuttleworth'));
-- Processor
INSERT INTO Processor (family, name, title, description, owner)
VALUES ((SELECT id FROM ProcessorFamily WHERE name = 'x86'),
'386', 'Intel 386',
'Intel 386 and its many derivatives and clones, the basic 32-bit chip in the x86 family',
(SELECT id FROM Person WHERE displayname = 'Mark Shuttleworth'));
-- Distribution
INSERT INTO Distribution (name, title, description, domainname, owner)
values ('ubuntu', 'Ubuntu',
'Ubuntu is a new concept of GNU/Linux Distribution based on Debian GNU/Linux.',
'domain', 1);
INSERT INTO Distribution (name, title, description, domainname, owner)
values ('redhat', 'Redhat Advanced Server',
'Red Hat is a commercial distribution of GNU/Linux Operating System.',
'domain', 1);
INSERT INTO Distribution (name, title, description, domainname, owner)
values ('debian', 'Debian GNU/Linux',
'Debian GNU/Linux is a non commercial distribution of a GNU/Linux Operating System for many platforms.',
'domain', 1);
INSERT INTO Distribution (name, title, description, domainname, owner)
values ('gentoo', 'The Gentoo Linux',
'Gentoo is a very customizeable GNU/Linux Distribution',
'domain', 1);
INSERT INTO Distribution (name, title, description, domainname, owner)
values ('porkypigpolka', 'Porky Pig Polka Distribution',
'Should be near the Spork concept of GNU/Linux Distribution',
'domain', 1);
-- Distrorelease
INSERT INTO Distrorelease (name, title, description, distribution, version,
datereleased, components, sections, releasestate, owner)
values
('warty', 'Warty', 'This is the first stable release of Ubuntu',
(SELECT id FROM Distribution WHERE name = 'ubuntu'),
'1.0.0',
'2004-08-20',
1, 1, 3, 1);
INSERT INTO Distrorelease (name, title, description, distribution, version,
datereleased, components, sections, releasestate, owner)
VALUES ('six', 'Six Six Six',
'some text to describe the whole 666 release of RH',
(SELECT id FROM Distribution WHERE name = 'redhat'),
'6.0.1',
'2004-03-21',
1, 1, 4, 8);
INSERT INTO Distrorelease (name, title, description, distribution, version,
datereleased, components, sections, releasestate, parentrelease,
owner)
VALUES ('hoary', 'Hoary Crazy-Unstable',
'Hoary is the next release of Ubuntu',
(SELECT id FROM Distribution WHERE name = 'ubuntu'),
'0.0.1',
'2004-08-25',
1, 1, 2,
(SELECT id FROM Distrorelease WHERE name = 'warty'),
1);
INSERT INTO Distrorelease (name, title, description, distribution, version,
datereleased, components, sections, releasestate, parentrelease,
owner)
VALUES ('7.0', 'Seven',
'The release that we would not expect',
(SELECT id FROM Distribution WHERE name = 'redhat'),
'7.0.1',
'2004-04-01',
1, 1, 3,
(SELECT id FROM Distrorelease WHERE name = 'six'),
7);
INSERT INTO Distrorelease (name, title, description, distribution, version,
datereleased, components, sections, releasestate, parentrelease,
owner)
VALUES ('grumpy', 'G-R-U-M-P-Y',
'Grumpy is far far away, but should be the third release of Ubuntu',
(SELECT id FROM Distribution WHERE name = 'ubuntu'),
'-0.0.1',
'2004-08-29',
1, 1, 1,
(SELECT id FROM Distrorelease WHERE name = 'warty'),
1);
INSERT INTO Distrorelease (name, title, description, distribution, version,
datereleased, components, sections, releasestate, owner)
VALUES ('woody', 'WOODY',
'WOODY is the current stable verison of Debian GNU/Linux',
(SELECT id FROM Distribution WHERE name = 'debian'),
'3.0',
'2003-01-01',
1, 1, 4, 2);
INSERT INTO Distrorelease (name, title, description, distribution, version,
datereleased, components, sections, releasestate, parentrelease,
owner)
VALUES ('sarge', 'Sarge',
'Sarge is the FROZEN unstable version of Debian GNU/Linux.',
(SELECT id FROM Distribution WHERE name = 'debian'),
'3.1',
'2004-09-29',
1, 1, 3,
(SELECT id FROM Distrorelease WHERE name = 'woody'),
5);
INSERT INTO Distrorelease (name, title, description, distribution, version,
datereleased, components, sections, releasestate, parentrelease,
owner)
VALUES ('sid', 'Sid',
'Sid is the CRAZY unstable version of Debian GNU/Linux.',
(SELECT id FROM Distribution WHERE name = 'debian'),
'3.2',
'2004-12-29',
1, 1, 1,
(SELECT id FROM Distrorelease WHERE name = 'woody'),
6);
--Distroreleaserole Persons ?!
INSERT INTO Distroreleaserole (person, distrorelease, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Mark Shuttleworth'),
(SELECT id from Distrorelease WHERE name = 'warty'),
1);
INSERT INTO Distroreleaserole (person, distrorelease, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Mark Shuttleworth'),
(SELECT id from Distrorelease WHERE name = 'hoary'),
1);
INSERT INTO Distroreleaserole (person, distrorelease, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Mark Shuttleworth'),
(SELECT id from Distrorelease WHERE name = 'grumpy'),
1);
INSERT INTO Distroreleaserole (person, distrorelease, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Steve Alexander'),
(SELECT id from Distrorelease WHERE name = 'warty'),
2);
INSERT INTO Distroreleaserole (person, distrorelease, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Steve Alexander'),
(SELECT id from Distrorelease WHERE name = 'hoary'),
2);
INSERT INTO Distroreleaserole (person, distrorelease, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Steve Alexander'),
(SELECT id from Distrorelease WHERE name = 'grumpy'),
3);
-- Distroreleaserole Teams ?!
INSERT INTO Distroreleaserole (person, distrorelease, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Warty Security Team'),
(SELECT id from Distrorelease WHERE name = 'warty'),
4);
INSERT INTO Distroreleaserole (person, distrorelease, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Warty Gnome Team'),
(SELECT id from Distrorelease WHERE name = 'warty'),
4);
INSERT INTO Distroreleaserole (person, distrorelease, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Hoary Gnome Team'),
(SELECT id from Distrorelease WHERE name = 'hoary'),
4);
--Distributionrole Persons ?!
INSERT INTO Distributionrole (person, distribution, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Mark Shuttleworth'),
(SELECT id from Distribution WHERE name = 'ubuntu'),
1);
INSERT INTO Distributionrole (person, distribution, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Steve Alexander'),
(SELECT id from Distribution WHERE name = 'ubuntu'),
1);
INSERT INTO Distributionrole (person, distribution, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Alexander Limi'),
(SELECT id from Distribution WHERE name = 'ubuntu'),
1);
INSERT INTO Distributionrole (person, distribution, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Andrew Bennetts'),
(SELECT id from Distribution WHERE name = 'ubuntu'),
1);
INSERT INTO Distributionrole (person, distribution, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Scott James Remnant'),
(SELECT id from Distribution WHERE name = 'ubuntu'),
1);
-- DistributionRole Teams ?!
INSERT INTO Distributionrole (person, distribution, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Ubuntu Team'),
(SELECT id from Distribution WHERE name = 'ubuntu'),
3);
INSERT INTO Distributionrole (person, distribution, role)
VALUES(
(SELECT id from Person WHERE displayname = 'Ubuntu Gnome Team'),
(SELECT id from Distribution WHERE name = 'ubuntu'),
3);
--DistroArchrelease
INSERT INTO Distroarchrelease(distrorelease, processorfamily, architecturetag,
owner) VALUES
((SELECT id FROM Distrorelease where name = 'warty'),
(SELECT id from Processorfamily where name = 'x86'),
'i386',
(SELECT id FROM Person WHERE displayname = 'Mark Shuttleworth')
);
INSERT INTO Distroarchrelease(distrorelease, processorfamily, architecturetag,
owner) VALUES
((SELECT id FROM Distrorelease where name = 'hoary'),
(SELECT id from Processorfamily where name = 'x86'),
'i386',
(SELECT id FROM Person WHERE displayname = 'Mark Shuttleworth')
);
INSERT INTO Distroarchrelease(distrorelease, processorfamily, architecturetag,
owner) VALUES
((SELECT id FROM Distrorelease where name = 'woody'),
(SELECT id from Processorfamily where name = 'x86'),
'i386',
(SELECT id FROM Person WHERE displayname = 'Mark Shuttleworth')
);
-- Build
INSERT INTO Build (datecreated, processor, distroarchrelease, buildstate)
VALUES
('2004-08-24',
(SELECT id FROM Processor where name = '386'),
1, -- hardcoded ?!?! use query instead
1 -- ??
);
|