msf 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (80) hide show
  1. data/.document +5 -0
  2. data/.rspec +1 -0
  3. data/Gemfile +24 -0
  4. data/Gemfile.lock +67 -0
  5. data/LICENSE.txt +20 -0
  6. data/README.md +45 -0
  7. data/Rakefile +43 -0
  8. data/VERSION +1 -0
  9. data/bin/ibspectra +43 -0
  10. data/erd/config.png +0 -0
  11. data/erd/empty.png +0 -0
  12. data/erd/erd.png +0 -0
  13. data/erd/msf.xcdatamodeld/.xccurrentversion +8 -0
  14. data/erd/msf.xcdatamodeld/msf.xcdatamodel/contents +330 -0
  15. data/erd/schema.txt +666 -0
  16. data/lib/msf.rb +2 -0
  17. data/lib/msf/models.rb +4 -0
  18. data/lib/msf/models/amino_acid.rb +50 -0
  19. data/lib/msf/models/amino_acid_modification.rb +55 -0
  20. data/lib/msf/models/amino_acid_modification_neutral_loss.rb +31 -0
  21. data/lib/msf/models/amino_acid_modifications_amino_acid_nls.rb +23 -0
  22. data/lib/msf/models/amino_acid_modifications_amino_acids.rb +27 -0
  23. data/lib/msf/models/annotation_data_version.rb +20 -0
  24. data/lib/msf/models/annotation_dataset.rb +29 -0
  25. data/lib/msf/models/annotation_group.rb +38 -0
  26. data/lib/msf/models/annotation_type.rb +23 -0
  27. data/lib/msf/models/chromatogram.rb +26 -0
  28. data/lib/msf/models/custom_data_field.rb +56 -0
  29. data/lib/msf/models/custom_data_peptide.rb +25 -0
  30. data/lib/msf/models/custom_data_processing_node.rb +25 -0
  31. data/lib/msf/models/custom_data_protein.rb +25 -0
  32. data/lib/msf/models/custom_data_spectrum.rb +25 -0
  33. data/lib/msf/models/enzyme.rb +32 -0
  34. data/lib/msf/models/fasta_file.rb +50 -0
  35. data/lib/msf/models/file_info.rb +41 -0
  36. data/lib/msf/models/mass_peak.rb +36 -0
  37. data/lib/msf/models/peptide.rb +118 -0
  38. data/lib/msf/models/peptide_score.rb +34 -0
  39. data/lib/msf/models/peptide_score_decoy.rb +34 -0
  40. data/lib/msf/models/peptide_terminal_modification.rb +29 -0
  41. data/lib/msf/models/peptides_amino_acid_modifications.rb +32 -0
  42. data/lib/msf/models/peptides_proteins.rb +27 -0
  43. data/lib/msf/models/processing_node.rb +65 -0
  44. data/lib/msf/models/processing_node_score.rb +45 -0
  45. data/lib/msf/models/protein.rb +38 -0
  46. data/lib/msf/models/protein_annotation.rb +35 -0
  47. data/lib/msf/models/protein_identification_group.rb +19 -0
  48. data/lib/msf/models/protein_score.rb +34 -0
  49. data/lib/msf/models/reporter_ion_quan_result.rb +31 -0
  50. data/lib/msf/models/reporter_ion_quan_result_search_spectrum.rb +29 -0
  51. data/lib/msf/models/scan_event.rb +37 -0
  52. data/lib/msf/models/schema_info.rb +29 -0
  53. data/lib/msf/models/spectrum.rb +34 -0
  54. data/lib/msf/models/spectrum_header.rb +63 -0
  55. data/lib/msf/models/spectrum_score.rb +24 -0
  56. data/lib/msf/models/taxonomy_name.rb +26 -0
  57. data/lib/msf/models/workflow_info.rb +46 -0
  58. data/lib/msf/models/workflow_message.rb +31 -0
  59. data/lib/msf/msf.rb +32 -0
  60. data/lib/msf/sql/enzyme_cleavage_specificity.rb +16 -0
  61. data/lib/msf/sql/false_discovery_rate.rb +24 -0
  62. data/lib/msf/sql/fasta_file_protein_annotation.rb +17 -0
  63. data/lib/msf/sql/mass_peak_relation.rb +17 -0
  64. data/lib/msf/sql/peptide_amino_acid_modification_decoy.rb +23 -0
  65. data/lib/msf/sql/peptide_decoy.rb +32 -0
  66. data/lib/msf/sql/peptide_terminal_modification_decoy.rb +20 -0
  67. data/lib/msf/sql/precursor_ion_quan_result.rb +29 -0
  68. data/lib/msf/sql/precursor_ion_quan_result_event_spectrum.rb +17 -0
  69. data/lib/msf/sql/precursor_ion_quan_result_search_spectrum.rb +20 -0
  70. data/lib/msf/sql/processing_node_filter_parameter.rb +29 -0
  71. data/lib/msf/sql/processing_node_interface.rb +19 -0
  72. data/lib/msf/sql/processing_node_parameter.rb +46 -0
  73. data/lib/msf/sql/processing_node_spectrum.rb +16 -0
  74. data/lib/msf/sql/quan_result.rb +40 -0
  75. data/lib/msf/sql/result_filter_set.rb +12 -0
  76. data/lib/msf/sql/taxonomy_node.rb +26 -0
  77. data/msf.gemspec +143 -0
  78. data/spec/msf_spec.rb +7 -0
  79. data/spec/spec_helper.rb +14 -0
  80. metadata +275 -0
@@ -0,0 +1,666 @@
1
+ CREATE TABLE [AminoAcidModifications] (
2
+ [AminoAcidModificationID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL ,
3
+ [ModificationName] [varchar] (250) COLLATE NOCASE NOT NULL ,
4
+ [DeltaMass] [double] NULL ,
5
+ [Substitution] [varchar] (50) COLLATE NOCASE NULL ,
6
+ [LeavingGroup] [varchar] (50) COLLATE NOCASE NULL ,
7
+ [Abbreviation] [varchar] (50) COLLATE NOCASE NOT NULL ,
8
+ [PositionType] [int] NOT NULL ,
9
+ [IsActive] [bit] NULL ,
10
+ [DeltaAverageMass] [double] NULL,
11
+ [UnimodAccession] [long] NULL,
12
+ [IsSubstitution] [bool] DEFAULT 0 NOT NULL,
13
+ UNIQUE (
14
+ [ModificationName],
15
+ [PositionType]
16
+ ),
17
+ UNIQUE (
18
+ [Abbreviation],
19
+ [PositionType]
20
+ )
21
+ );
22
+ CREATE TABLE [AminoAcidModificationsAminoAcids] (
23
+ [AminoAcidModificationID] [int] NOT NULL ,
24
+ [AminoAcidID] [int] NOT NULL ,
25
+ [Classification][int] NOT NULL,
26
+ PRIMARY KEY ( [AminoAcidModificationID],[AminoAcidID] )
27
+ );
28
+ CREATE TABLE [AminoAcidModificationsAminoAcidsNL] (
29
+ [AminoAcidModificationID] [int] NOT NULL ,
30
+ [AminoAcidID] [int] NOT NULL ,
31
+ [NeutralLossID] [int] NOT NULL ,
32
+ PRIMARY KEY ( [AminoAcidModificationID],[AminoAcidID], [NeutralLossID] )
33
+ );
34
+ CREATE TABLE [AminoAcidModificationsNeutralLosses](
35
+ [NeutralLossID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL ,
36
+ [Name] [varchar] (50) COLLATE NOCASE NOT NULL ,
37
+ [MonoisotopicMass] [double] NOT NULL ,
38
+ [AverageMass] [double] NOT NULL
39
+ );
40
+ CREATE TABLE [AminoAcids] (
41
+ [AminoAcidID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL ,
42
+ [AminoAcidName] [varchar] (50) COLLATE NOCASE NOT NULL ,
43
+ [OneLetterCode] [char] (1) NULL ,
44
+ [ThreeLetterCode] [char] (3) COLLATE NOCASE UNIQUE NULL ,
45
+ [MonoisotopicMass] [double] NOT NULL ,
46
+ [AverageMass] [double] NOT NULL ,
47
+ [SumFormula] [varchar] (50) COLLATE NOCASE NULL
48
+ );
49
+ CREATE TABLE AnnotationDataVersion(
50
+ [PcDataVersion] INTEGER PRIMARY KEY NOT NULL,
51
+ [PcDataRelease] [bigint] NOT NULL
52
+ );
53
+ CREATE TABLE AnnotationDataset(
54
+ [DatasetId] INTEGER PRIMARY KEY NOT NULL ,
55
+ [Name] [varchar] (50) COLLATE NOCASE NOT NULL ,
56
+ [DisplayName] [varchar] (30) COLLATE NOCASE NOT NULL ,
57
+ [Guid] [varchar] (50) COLLATE NOCASE NOT NULL,
58
+ [Description] [text]
59
+ );
60
+ CREATE TABLE AnnotationGroups(
61
+ [AnnotationGroupId] [int] NOT NULL,
62
+ [Description] [text],
63
+ [DatasetId] [int] NOT NULL,
64
+ [Position][int] NOT NULL,
65
+ [ColorR][int] NOT NULL,
66
+ [ColorG][int] NOT NULL,
67
+ [ColorB][int] NOT NULL,
68
+ [GroupDefinition][Blob],
69
+ PRIMARY KEY (
70
+ [AnnotationGroupId],
71
+ [DatasetId]
72
+ )
73
+ );
74
+ CREATE TABLE AnnotationTypes(
75
+ [AnnotationTypeId] INTEGER PRIMARY KEY NOT NULL ,
76
+ [Name] [varchar] (30) COLLATE NOCASE NOT NULL ,
77
+ [Description] [text]
78
+ );
79
+ CREATE TABLE Annotations(
80
+ [AnnotationId] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL ,
81
+ [Accession] [varchar] (30) COLLATE NOCASE NOT NULL ,
82
+ [Description] [text],
83
+ [type] [int]
84
+ );
85
+ CREATE TABLE AnnotationsAnnotationGroups(
86
+ [AnnotationId] [int] NOT NULL,
87
+ [AnnotationGroupId] [int] NOT NULL,
88
+ PRIMARY KEY (
89
+ [AnnotationId],
90
+ [AnnotationGroupId]
91
+ )
92
+ );
93
+ CREATE TABLE AnnotationsProtein(
94
+ [proteinID] [int] NOT NULL ,
95
+ [AnnotationId] [int] NOT NULL,
96
+ [Evidence] [int],
97
+ [PositionBegin][int],
98
+ [PositionEnd][int],
99
+ [ProteinAccession] [varchar] (30) COLLATE NOCASE NOT NULL,
100
+ PRIMARY KEY (
101
+ [proteinID],
102
+ [AnnotationId],
103
+ [Evidence],
104
+ [PositionBegin],
105
+ [ProteinAccession]
106
+ )
107
+ );
108
+ CREATE TABLE Chromatograms (
109
+ [FileID] [int] NOT NULL,
110
+ [TraceType] [int] NOT NULL,
111
+ [Chromatogram] [binary] NOT NULL,
112
+ PRIMARY KEY (
113
+ [FileID],
114
+ [TraceType]
115
+ )
116
+ );
117
+ CREATE TABLE CustomDataFields (
118
+ [FieldID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL ,
119
+ [Guid] [varchar] (50) COLLATE NOCASE NOT NULL,
120
+ [DisplayName][varchar](50) COLLATE NOCASE NOT NULL,
121
+ [SourceNodeNumber] [int] NOT NULL,
122
+ [TargetNodeNumber] [int] NOT NULL,
123
+ [DataType][int] NOT NULL,
124
+ [DataTarget][int] NOT NULL,
125
+ [Version][double] NOT NULL,
126
+ [AccessMode][int] DEFAULT 0,
127
+ [Visibility][int] DEFAULT 0,
128
+ [GroupVisibility][int] DEFAULT 0,
129
+ [Format][varchar](20),
130
+ [PlotType][int] NOT NULL,
131
+ [DataPurpose][varchar](250)
132
+ );
133
+ CREATE TABLE CustomDataPeptides (
134
+ [FieldID] [int] NOT NULL,
135
+ [PeptideID] [int] NOT NULL,
136
+ [FieldValue] [variant],
137
+ PRIMARY KEY (
138
+ [FieldID],
139
+ [PeptideID]
140
+ )
141
+ );
142
+ CREATE TABLE CustomDataPeptides_decoy (
143
+ [FieldID] [int] NOT NULL,
144
+ [PeptideID] [int] NOT NULL,
145
+ [FieldValue] [variant],
146
+ PRIMARY KEY (
147
+ [FieldID],
148
+ [PeptideID]
149
+ )
150
+ );
151
+ CREATE TABLE CustomDataProcessingNodes (
152
+ [FieldID] [int] NOT NULL,
153
+ [ProcessingNodeNumber] [int] NOT NULL,
154
+ [FieldValue] [variant],
155
+ PRIMARY KEY (
156
+ [FieldID],
157
+ [ProcessingNodeNumber]
158
+ )
159
+ );
160
+ CREATE TABLE CustomDataProteins (
161
+ [FieldID] [int] NOT NULL,
162
+ [ProteinID] [int] NOT NULL,
163
+ [FieldValue] [variant],
164
+ PRIMARY KEY (
165
+ [FieldID],
166
+ [ProteinID]
167
+ )
168
+ );
169
+ CREATE TABLE CustomDataProteins_decoy (
170
+ [FieldID] [int] NOT NULL,
171
+ [ProteinID] [int] NOT NULL,
172
+ [FieldValue] [variant],
173
+ PRIMARY KEY (
174
+ [FieldID],
175
+ [ProteinID]
176
+ )
177
+ );
178
+ CREATE TABLE CustomDataSpectra (
179
+ [FieldID] [int] NOT NULL,
180
+ [SpectrumID] [int] NOT NULL,
181
+ [FieldValue] [variant],
182
+ PRIMARY KEY (
183
+ [FieldID],
184
+ [SpectrumID]
185
+ )
186
+ );
187
+ CREATE TABLE [Enzymes] (
188
+ [EnzymeID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL ,
189
+ [Name] [varchar] (25) UNIQUE COLLATE NOCASE NOT NULL ,
190
+ [Abbreviation] [varchar] (5) COLLATE NOCASE NOT NULL ,
191
+ [Seperator] [varchar] (10) COLLATE NOCASE NOT NULL ,
192
+ [NonSeperator] [varchar] (10) COLLATE NOCASE NOT NULL ,
193
+ [Offset] [int] NOT NULL
194
+ );
195
+ CREATE TABLE [EnzymesCleavageSpecificities] (
196
+ [EnzymeID] [int] NOT NULL ,
197
+ [Specificity] [int] NOT NULL ,
198
+ PRIMARY KEY (EnzymeID, Specificity)
199
+ );
200
+ CREATE TABLE [EventAnnotations] (
201
+ [EventID] INTEGER PRIMARY KEY NOT NULL,
202
+ [Charge] [smallint] NOT NULL,
203
+ [IsotopePatternID] [int] NOT NULL,
204
+ [QuanResultID] [int] NOT NULL,
205
+ [QuanChannelID] [int] NOT NULL
206
+ );
207
+ CREATE TABLE [EventAreaAnnotations] (
208
+ [EventID] INTEGER PRIMARY KEY NOT NULL,
209
+ [Charge] [smallint] NOT NULL,
210
+ [IsotopePatternID] [int] NOT NULL,
211
+ [QuanResultID] [int] NOT NULL
212
+ );
213
+ CREATE TABLE [Events] (
214
+ [EventID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
215
+ [Mass] [double] NOT NULL,
216
+ [MassAvg] [double] NOT NULL,
217
+ [Area] [float] NOT NULL,
218
+ [Intensity] [float] NOT NULL,
219
+ [PeakWidth] [float] NOT NULL,
220
+ [RT] [double] NOT NULL,
221
+ [LeftRT] [float] NOT NULL,
222
+ [RightRT] [float] NOT NULL,
223
+ [SN][float] DEFAULT 0.0 NOT NULL,
224
+ [FileID] [int] NOT NULL
225
+ );
226
+ CREATE TABLE [FastaFiles] (
227
+ [FastaFileID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL ,
228
+ [FileName] [varchar] (256) UNIQUE COLLATE NOCASE NOT NULL ,
229
+ [State] [int] NOT NULL ,
230
+ [VirtualFileName] [varchar] (256) COLLATE NOCASE NOT NULL ,
231
+ [FileSize] [bigint] NOT NULL ,
232
+ [FileTime] [bigint] NOT NULL ,
233
+ [NumberOfProteins] [bigint] NULL ,
234
+ [NumberOfAminoAcids] [bigint] NULL ,
235
+ [FileHashCode] [bigint] NULL ,
236
+ [Hidden] [bit] NOT NULL ,
237
+ [IsSrfImport] [bit] NOT NULL ,
238
+ [IsScheduledForDeletion] [bit] DEFAULT 0 NOT NULL
239
+ );
240
+ CREATE TABLE [FastaFilesProteinAnnotations] (
241
+ [FastaFileID] [int] NOT NULL ,
242
+ [ProteinAnnotationID] [int] NOT NULL ,
243
+ PRIMARY KEY (
244
+ [FastaFileID],
245
+ [ProteinAnnotationID]
246
+ )
247
+ );
248
+ CREATE TABLE [FileInfos] (
249
+ [FileID] [int] PRIMARY KEY NOT NULL ,
250
+ [FileName] [varchar] (2048) COLLATE NOCASE NOT NULL ,
251
+ [FileTime] [datetime] NOT NULL ,
252
+ [FileSize] [bigint] NOT NULL ,
253
+ [PhysicalFileName] [varchar] (2048) COLLATE NOCASE NOT NULL ,
254
+ [FileType] [smallint] NOT NULL
255
+ );
256
+ CREATE TABLE [MassPeakRelations] (
257
+ [MassPeakID] [int] NOT NULL,
258
+ [RelatedMassPeakID] [int] NOT NULL,
259
+ PRIMARY KEY (
260
+ [MassPeakID],
261
+ [RelatedMassPeakID]
262
+ )
263
+ );
264
+ CREATE TABLE [MassPeaks] (
265
+ [MassPeakID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
266
+ [Charge] [smallint] NULL ,
267
+ [Intensity] [double] NULL ,
268
+ [Mass] [double] NULL ,
269
+ [ScanNumbers] [varchar](1000) NULL,
270
+ [FileID] [int] NULL,
271
+ [PercentIsolationInterference] [float] NULL,
272
+ [IonInjectTime] [int] NULL,
273
+ UNIQUE(
274
+ [Charge],
275
+ [Mass],
276
+ [ScanNumbers],
277
+ [FileID]
278
+ )
279
+ );
280
+ CREATE TABLE [PeptideScores] (
281
+ [ProcessingNodeNumber] [int] NOT NULL ,
282
+ [PeptideID] [int] NOT NULL ,
283
+ [ScoreID] [int] NOT NULL ,
284
+ [ProcessingNodeID] [int] NULL ,
285
+ [ScoreValue] [double] NOT NULL ,
286
+ PRIMARY KEY (
287
+ [ProcessingNodeNumber],
288
+ [PeptideID],
289
+ [ScoreID]
290
+ )
291
+ );
292
+ CREATE TABLE [PeptideScores_decoy] (
293
+ [ProcessingNodeNumber] [int] NOT NULL ,
294
+ [PeptideID] [int] NOT NULL ,
295
+ [ScoreID] [int] NOT NULL ,
296
+ [ProcessingNodeID] [int] NULL ,
297
+ [ScoreValue] [double] NOT NULL,
298
+ PRIMARY KEY (
299
+ [ProcessingNodeNumber],
300
+ [PeptideID],
301
+ [ScoreID]
302
+ )
303
+ );
304
+ CREATE TABLE [Peptides] (
305
+ [ProcessingNodeNumber] [int] NOT NULL ,
306
+ [PeptideID] [int] NOT NULL ,
307
+ [SpectrumID] [int] NOT NULL ,
308
+ [TotalIonsCount] [smallint] NOT NULL ,
309
+ [MatchedIonsCount] [smallint] NOT NULL ,
310
+ [ConfidenceLevel] [smallint] NOT NULL ,
311
+ [SearchEngineRank] [int] NOT NULL,
312
+ [Hidden] [bit] DEFAULT 0 NOT NULL ,
313
+ [Sequence] [varchar] (1024) COLLATE NOCASE NULL,
314
+ [Annotation] [varchar] (1024) COLLATE NOCASE NULL ,
315
+ [UniquePeptideSequenceID] [int] DEFAULT 1 NOT NULL,
316
+ [MissedCleavages] [smallint] NOT NULL,
317
+ PRIMARY KEY (
318
+ [ProcessingNodeNumber],
319
+ [PeptideID]
320
+ )
321
+ );
322
+ CREATE TABLE [PeptidesAminoAcidModifications] (
323
+ [ProcessingNodeNumber] [int] NOT NULL ,
324
+ [PeptideID] [int] NOT NULL ,
325
+ [AminoAcidModificationID] [int] NOT NULL ,
326
+ [Position] [int] NOT NULL ,
327
+ PRIMARY KEY (
328
+ [ProcessingNodeNumber],
329
+ [PeptideID],
330
+ [AminoAcidModificationID],
331
+ [Position]
332
+ )
333
+ );
334
+ CREATE TABLE [PeptidesAminoAcidModifications_decoy] (
335
+ [ProcessingNodeNumber] [int] NOT NULL ,
336
+ [PeptideID] [int] NOT NULL ,
337
+ [AminoAcidModificationID] [int] NOT NULL ,
338
+ [Position] [int] NOT NULL,
339
+ PRIMARY KEY (
340
+ [ProcessingNodeNumber],
341
+ [PeptideID],
342
+ [AminoAcidModificationID],
343
+ [Position]
344
+ )
345
+ );
346
+ CREATE TABLE [PeptidesProteins] (
347
+ [ProcessingNodeNumber] [int] NOT NULL ,
348
+ [PeptideID] [int] NOT NULL ,
349
+ [ProteinID] [int] NOT NULL ,
350
+ PRIMARY KEY (
351
+ [ProcessingNodeNumber],
352
+ [PeptideID],
353
+ [ProteinID]
354
+ )
355
+ );
356
+ CREATE TABLE [PeptidesProteins_decoy] (
357
+ [ProcessingNodeNumber] [int] NOT NULL ,
358
+ [PeptideID] [int] NOT NULL ,
359
+ [ProteinID] [int] NOT NULL ,
360
+ PRIMARY KEY (
361
+ [ProcessingNodeNumber],
362
+ [PeptideID],
363
+ [ProteinID]
364
+ )
365
+ );
366
+ CREATE TABLE [PeptidesTerminalModifications] (
367
+ [ProcessingNodeNumber] [int] NOT NULL ,
368
+ [PeptideID] [int] NOT NULL ,
369
+ [TerminalModificationID] [int] NOT NULL ,
370
+ PRIMARY KEY (
371
+ [ProcessingNodeNumber],
372
+ [PeptideID],
373
+ [TerminalModificationID]
374
+ )
375
+ );
376
+ CREATE TABLE [PeptidesTerminalModifications_decoy] (
377
+ [ProcessingNodeNumber] [int] NOT NULL ,
378
+ [PeptideID] [int] NOT NULL ,
379
+ [TerminalModificationID] [int] NOT NULL ,
380
+ PRIMARY KEY (
381
+ [ProcessingNodeNumber],
382
+ [PeptideID],
383
+ [TerminalModificationID]
384
+ )
385
+ );
386
+ CREATE TABLE [Peptides_decoy] (
387
+ [ProcessingNodeNumber] [int] NOT NULL ,
388
+ [PeptideID] [int] NOT NULL ,
389
+ [SpectrumID] [int] NOT NULL ,
390
+ [TotalIonsCount] [smallint] NOT NULL ,
391
+ [MatchedIonsCount] [smallint] NOT NULL ,
392
+ [ConfidenceLevel] [smallint] NOT NULL ,
393
+ [SearchEngineRank] [int] NOT NULL,
394
+ [Sequence] [varchar] (1024) COLLATE NOCASE NULL,
395
+ [Annotation] [varchar] (1024) COLLATE NOCASE NULL ,
396
+ [UniquePeptideSequenceID] int DEFAULT 1 NOT NULL,
397
+ [MissedCleavages] [smallint] NOT NULL,
398
+ PRIMARY KEY (
399
+ [ProcessingNodeNumber],
400
+ [PeptideID]
401
+ )
402
+ );
403
+ CREATE TABLE [PrecursorIonAreaSearchSpectra] (
404
+ [QuanResultID] [int] NOT NULL ,
405
+ [SearchSpectrumID] [int] NULL
406
+ );
407
+ CREATE TABLE [PrecursorIonQuanResults] (
408
+ [QuanChannelID][int] NOT NULL,
409
+ [QuanResultID][int] NOT NULL,
410
+ [Mass] [double] NOT NULL ,
411
+ [Charge] [int] NOT NULL ,
412
+ [Area] [double] NULL ,
413
+ [RetentionTime] [double] NULL
414
+ );
415
+ CREATE TABLE [PrecursorIonQuanResultsSearchSpectra] (
416
+ [ProcessingNodeNumber] [int] NOT NULL ,
417
+ [QuanResultID] [int] NOT NULL ,
418
+ [SearchSpectrumID] [int] NULL
419
+ );
420
+ CREATE TABLE [ProcessingNodeConnectionPoints] (
421
+ [ProcessingNodeID] INTEGER NOT NULL,
422
+ [Interface] [varchar] (256) NOT NULL,
423
+ [ConnectionDirection] [int] NOT NULL,
424
+ [ConnectionMode] [int] NOT NULL,
425
+ [ConnectionMultiplicity] [int] NOT NULL,
426
+ [ConnectionRequirement] [int] NOT NULL,
427
+ [DataTypeSpecialization] [varchar] (256) NOT NULL,
428
+ [ConnectionDisplayName] [varchar] (256) NOT NULL
429
+ );
430
+ CREATE TABLE ProcessingNodeExtensions(
431
+ [ExtensionID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
432
+ [ProcessingNodeNumber] [int] NOT NULL,
433
+ [Guid] [varchar] (36) COLLATE NOCASE NOT NULL,
434
+ [Purpose] [varchar](256) COLLATE NOCASE NOT NULL,
435
+ [PurposeDetail] [varchar](256) COLLATE NOCASE NULL,
436
+ [MajorVersion] [int] NOT NULL,
437
+ [MinorVersion] [int] NOT NULL,
438
+ [Settings] [text]
439
+ );
440
+ CREATE TABLE [ProcessingNodeFilterParameters] (
441
+ [ProcessingNodeNumber] [int] NOT NULL ,
442
+ [FilterParameterName] [varchar] (50) COLLATE NOCASE NOT NULL ,
443
+ [FilterModuleTypeID] [int] NOT NULL ,
444
+ [FilterModuleNumber] [int] NOT NULL ,
445
+ [ProcessingNodeID] [int] NOT NULL ,
446
+ [FilterParameterValue] [double] NOT NULL ,
447
+ PRIMARY KEY ( [ProcessingNodeNumber], [FilterParameterName])
448
+ );
449
+ CREATE TABLE [ProcessingNodeInterfaces] (
450
+ [ProcessingNodeID] INTEGER NOT NULL,
451
+ [InterfaceKind] [int] NOT NULL,
452
+ [InterfaceName] [varchar] (256) NOT NULL
453
+ );
454
+ CREATE TABLE [ProcessingNodeParameters] (
455
+ [ProcessingNodeNumber] [int] NOT NULL ,
456
+ [ParameterName] [varchar] (50) COLLATE NOCASE NOT NULL ,
457
+ [FriendlyName] [varchar](256) COLLATE NOCASE NOT NULL,
458
+ [ProcessingNodeID] [int] NOT NULL ,
459
+ [IntendedPurpose] [int] NOT NULL,
460
+ [PurposeDetails] [varchar] (1024) COLLATE NOCASE NOT NULL,
461
+ [Hidden] [bit] NOT NULL,
462
+ [Advanced] [bit] NOT NULL,
463
+ [Category] [varchar] (50) COLLATE NOCASE NOT NULL,
464
+ [Position] [int] NOT NULL,
465
+ [ParameterValue] [varchar] (50) COLLATE NOCASE NOT NULL ,
466
+ [ValueDisplayString] [varchar] (1024) COLLATE NOCASE NOT NULL,
467
+ PRIMARY KEY ( [ProcessingNodeNumber], [ParameterName] )
468
+ );
469
+ CREATE TABLE [ProcessingNodeScores] (
470
+ [ProcessingNodeID] [int] NOT NULL ,
471
+ [ScoreID] INTEGER PRIMARY KEY AUTOINCREMENT ,
472
+ [ScoreName] [varchar] (50) COLLATE NOCASE NOT NULL ,
473
+ [FriendlyName] [varchar](256) COLLATE NOCASE NOT NULL,
474
+ [Description] [varchar](1024) COLLATE NOCASE NOT NULL,
475
+ [FormatString] [varchar](64) COLLATE NOCASE NOT NULL,
476
+ [ScoreCategory] [int] NOT NULL,
477
+ [Hidden] [bit] NOT NULL,
478
+ [IsMainScore] [bit] NOT NULL,
479
+ [ScoreGUID] [varchar] (36) COLLATE NOCASE NOT NULL,
480
+ UNIQUE ([ProcessingNodeID], [ScoreName])
481
+ );
482
+ CREATE TABLE [ProcessingNodes] (
483
+ [ProcessingNodeNumber] [int] PRIMARY KEY NOT NULL ,
484
+ [ProcessingNodeID] [int] NOT NULL ,
485
+ [ProcessingNodeParentNumber] [varchar] (36) COLLATE NOCASE NOT NULL ,
486
+ [NodeName] [varchar] (128) COLLATE NOCASE NULL ,
487
+ [FriendlyName] [varchar](256) COLLATE NOCASE NOT NULL,
488
+ [MajorVersion] [int] NOT NULL ,
489
+ [MinorVersion] [int] NOT NULL ,
490
+ [NodeComment] [varchar] (256) COLLATE NOCASE NULL ,
491
+ [NodeGUID] [varchar] (36) COLLATE NOCASE NOT NULL,
492
+ [ProcessingNodeState] [int] DEFAULT 0 NOT NULL
493
+ );
494
+ CREATE TABLE ProcessingNodesSpectra (
495
+ [SendingProcessingNodeNumber] [int] NOT NULL,
496
+ [SpectrumID] [int] NOT NULL,
497
+ PRIMARY KEY (
498
+ [SendingProcessingNodeNumber],
499
+ [SpectrumID]
500
+ )
501
+ );
502
+ CREATE TABLE [ProteinAnnotations] (
503
+ [ProteinAnnotationID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL ,
504
+ [ProteinID] [int] NOT NULL ,
505
+ [DescriptionHashCode] [bigint] NOT NULL ,
506
+ [Description] [text] NOT NULL,
507
+ [TaxonomyID] [int] NOT NULL
508
+ );
509
+ CREATE TABLE [ProteinIdentificationGroups] (
510
+ [ProteinIdentificationGroupId] [int] NOT NULL,
511
+ [ProcessingNodeNumber] [int] NOT NULL,
512
+ PRIMARY KEY (
513
+ [ProteinIdentificationGroupId],
514
+ [ProcessingNodeNumber]
515
+ )
516
+ );
517
+ CREATE TABLE [ProteinScores] (
518
+ [ProcessingNodeNumber] [int] NOT NULL,
519
+ [ProteinID] [int] NOT NULL ,
520
+ [ProteinIdentificationGroupID] [int] NOT NULL ,
521
+ [ProteinScore] [double] NOT NULL ,
522
+ [Coverage] [double] DEFAULT 0 NOT NULL ,
523
+ PRIMARY KEY (
524
+ [ProcessingNodeNumber],
525
+ [ProteinID]
526
+ )
527
+ );
528
+ CREATE TABLE [ProteinScores_decoy] (
529
+ [ProcessingNodeNumber] [int] NOT NULL,
530
+ [ProteinID] [int] NOT NULL ,
531
+ [ProteinIdentificationGroupID] [int] NOT NULL ,
532
+ [ProteinScore] [double] NOT NULL ,
533
+ [Coverage] [double] DEFAULT 0 NOT NULL ,
534
+ PRIMARY KEY (
535
+ [ProcessingNodeNumber],
536
+ [ProteinID]
537
+ )
538
+ );
539
+ CREATE TABLE [Proteins] (
540
+ [ProteinID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL ,
541
+ [Sequence] [text] NOT NULL ,
542
+ [SequenceHashCode] [bigint] NOT NULL
543
+ , [IsMasterProtein] [bit] DEFAULT 0 NOT NULL);
544
+ CREATE TABLE [ProteinsProteinGroups](
545
+ [ProteinID] [int] NOT NULL,
546
+ [ProteinGroupID] [int] NOT NULL
547
+ );
548
+ CREATE TABLE PtmAnnotationData(
549
+ [ProteinId] INTEGER NOT NULL,
550
+ [PtmUnimodId] INTEGER NOT NULL,
551
+ [Position] INTEGER NOT NULL,
552
+ PRIMARY KEY (
553
+ [ProteinId],
554
+ [PtmUnimodId],
555
+ [Position]
556
+ )
557
+ );
558
+ CREATE TABLE [ReporterIonQuanResults] (
559
+ [ProcessingNodeNumber] [int] NOT NULL ,
560
+ [QuanChannelID] [int] NOT NULL ,
561
+ [SpectrumID] [int] NOT NULL ,
562
+ [Mass] [double] NOT NULL ,
563
+ [Height] [double] NULL ,
564
+ PRIMARY KEY (
565
+ [ProcessingNodeNumber],
566
+ [QuanChannelID],
567
+ [SpectrumID]
568
+ )
569
+ );
570
+ CREATE TABLE [ReporterIonQuanResultsSearchSpectra] (
571
+ [ProcessingNodeNumber] [int] NOT NULL ,
572
+ [SpectrumID] [int] NOT NULL ,
573
+ [SearchSpectrumID] [int] NULL
574
+ );
575
+ CREATE TABLE [ScanEvents] (
576
+ [ScanEventID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL ,
577
+ [MSLevel] [tinyint] NOT NULL ,
578
+ [Polarity] [tinyint] NOT NULL ,
579
+ [ScanType] [tinyint] NOT NULL ,
580
+ [Ionization] [tinyint] NOT NULL ,
581
+ [MassAnalyzer] [tinyint] NOT NULL ,
582
+ [ActivationType] [tinyint] NOT NULL ,
583
+ UNIQUE (
584
+ [MSLevel],
585
+ [Polarity],
586
+ [ScanType],
587
+ [Ionization],
588
+ [MassAnalyzer],
589
+ [ActivationType]
590
+ )
591
+ );
592
+ CREATE TABLE [SchemaInfo] (
593
+ [Version] [int] PRIMARY KEY NOT NULL,
594
+ [Kind] [varchar] (32) NOT NULL,
595
+ [Date] [datetime] NOT NULL,
596
+ [SoftwareVersion] [varchar] (64) NOT NULL,
597
+ [Comment] [text] NOT NULL
598
+ );
599
+ CREATE TABLE Spectra (
600
+ [UniqueSpectrumID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL ,
601
+ [Spectrum] [binary] NOT NULL,
602
+ [SpectrumHashCode] [bigint] NULL
603
+ );
604
+ CREATE TABLE [SpectrumHeaders] (
605
+ [SpectrumID] [INTEGER] PRIMARY KEY NOT NULL ,
606
+ [MassPeakID] [int] NULL ,
607
+ [ScanEventID] [int] NULL ,
608
+ [LastScan] [int] NULL ,
609
+ [FirstScan] [int] NULL ,
610
+ [RetentionTime] [double] NULL ,
611
+ [Hidden] [bit] DEFAULT 0 NOT NULL ,
612
+ [ScanNumbers] [varchar](1000) NULL ,
613
+ [Charge] [smallint] NULL ,
614
+ [Mass] [double] NULL,
615
+ [CreatingProcessingNodeNumber] [int] NOT NULL,
616
+ [UniqueSpectrumID] [int] DEFAULT 0 NOT NULL
617
+ );
618
+ CREATE TABLE SpectrumScores (
619
+ [ProcessingNodeNumber] [int] NOT NULL,
620
+ [SpectrumID] [int] NOT NULL,
621
+ [Score] [double] NOT NULL,
622
+ PRIMARY KEY (
623
+ [SpectrumID],
624
+ [ProcessingNodeNumber]
625
+ )
626
+ );
627
+ CREATE TABLE [TaxonomyNames] (
628
+ [TaxonomyID] INTEGER NOT NULL ,
629
+ [Name] [varchar](1024) COLLATE NOCASE NULL ,
630
+ [NameCategory] INTEGER NOT NULL ,
631
+ UNIQUE (
632
+ TaxonomyID,
633
+ Name,
634
+ NameCategory
635
+ )
636
+ );
637
+ CREATE TABLE [TaxonomyNodes] (
638
+ [TaxonomyID] INTEGER PRIMARY KEY NOT NULL ,
639
+ [ParentTaxonomyID] INTEGER NOT NULL ,
640
+ [TaxonomyRank] INTEGER NOT NULL ,
641
+ [LeftNodeIndex] INTEGER NOT NULL ,
642
+ [RightNodeIndex] INTEGER NOT NULL,
643
+ UNIQUE (TaxonomyID)
644
+ );
645
+ CREATE TABLE [WorkflowInfo] (
646
+ [WorkflowName] [varchar] (256) COLLATE NOCASE NOT NULL ,
647
+ [WorkflowDescription] [varchar] (256) COLLATE NOCASE NOT NULL ,
648
+ [WorkflowState] [int] DEFAULT 0 NOT NULL ,
649
+ [WorkflowStartDate] [datetime] NOT NULL ,
650
+ [WorkflowTemplate] [varchar] (256) NOT NULL ,
651
+ [User] [varchar] (256) COLLATE NOCASE NOT NULL ,
652
+ [WorkflowGUID] [varchar] (36) COLLATE NOCASE NOT NULL ,
653
+ [MachineGUID] [varchar] (36) COLLATE NOCASE NOT NULL ,
654
+ [MachineName] [varchar] (256) COLLATE NOCASE NOT NULL,
655
+ [MergeSimilarIdentificationResults] [bit] NOT NULL,
656
+ [IsValid] [bit] NOT NULL,
657
+ [Version] [int] NOT NULL
658
+ );
659
+ CREATE TABLE [WorkflowMessages] (
660
+ [MessageID] INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
661
+ [ProcessingNodeID] [int] NOT NULL ,
662
+ [ProcessingNodeNumber] [int] NOT NULL ,
663
+ [Time] [bigint] NOT NULL ,
664
+ [MessageKind] [int] NOT NULL ,
665
+ [Message] [varchar] (1024) COLLATE NOCASE NOT NULL
666
+ );