Commit 12dcd869 authored by Ameya Chaubal's avatar Ameya Chaubal

patch test db for 101

parent f320b0f6
Pipeline #65114 passed with stage
in 5 minutes and 46 seconds
1 \N schema_version 100
1 \N schema_version 101
2 1 assembly.default NCBI34
3 1 species.taxonomy_id 9606
26 1 species.classification Homo sapiens
......@@ -114,3 +114,5 @@
188 \N patch patch_98_99_a.sql|schema_version
189 \N patch patch_99_100_a.sql|schema_version
190 \N patch patch_99_100_b.sql|alter_externaldb_type_notnull
191 \N patch patch_99_100_c.sql|alter_mapping_session_assembly_length
192 \N patch patch_100_101_a.sql|schema_version
......@@ -28,7 +28,7 @@ CREATE TABLE `analysis` (
`program` varchar(80) COLLATE latin1_bin DEFAULT NULL,
`program_version` varchar(40) COLLATE latin1_bin DEFAULT NULL,
`program_file` varchar(80) COLLATE latin1_bin DEFAULT NULL,
`parameters` text COLLATE latin1_bin DEFAULT NULL,
`parameters` text COLLATE latin1_bin,
`module` varchar(80) COLLATE latin1_bin DEFAULT NULL,
`module_version` varchar(40) COLLATE latin1_bin DEFAULT NULL,
`gff_source` varchar(40) COLLATE latin1_bin DEFAULT NULL,
......@@ -38,22 +38,22 @@ CREATE TABLE `analysis` (
) ENGINE=MyISAM AUTO_INCREMENT=8415 DEFAULT CHARSET=latin1 COLLATE=latin1_bin;
CREATE TABLE `analysis_description` (
`analysis_id` int(10) unsigned NOT NULL DEFAULT 0,
`description` text COLLATE latin1_bin DEFAULT NULL,
`analysis_id` int(10) unsigned NOT NULL DEFAULT '0',
`description` text COLLATE latin1_bin,
`display_label` varchar(255) COLLATE latin1_bin DEFAULT NULL,
`displayable` tinyint(1) NOT NULL DEFAULT 1,
`web_data` text COLLATE latin1_bin DEFAULT NULL,
`displayable` tinyint(1) NOT NULL DEFAULT '1',
`web_data` text COLLATE latin1_bin,
UNIQUE KEY `analysis_idx` (`analysis_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_bin;
CREATE TABLE `assembly` (
`asm_seq_region_id` int(10) unsigned NOT NULL DEFAULT 0,
`cmp_seq_region_id` int(10) unsigned NOT NULL DEFAULT 0,
`asm_start` int(10) NOT NULL DEFAULT 0,
`asm_end` int(10) NOT NULL DEFAULT 0,
`cmp_start` int(10) NOT NULL DEFAULT 0,
`cmp_end` int(10) NOT NULL DEFAULT 0,
`ori` tinyint(4) NOT NULL DEFAULT 0,
`asm_seq_region_id` int(10) unsigned NOT NULL DEFAULT '0',
`cmp_seq_region_id` int(10) unsigned NOT NULL DEFAULT '0',
`asm_start` int(10) NOT NULL DEFAULT '0',
`asm_end` int(10) NOT NULL DEFAULT '0',
`cmp_start` int(10) NOT NULL DEFAULT '0',
`cmp_end` int(10) NOT NULL DEFAULT '0',
`ori` tinyint(4) NOT NULL DEFAULT '0',
UNIQUE KEY `all_idx` (`asm_seq_region_id`,`cmp_seq_region_id`,`asm_start`,`asm_end`,`cmp_start`,`cmp_end`,`ori`),
KEY `cmp_seq_region_id` (`cmp_seq_region_id`),
KEY `asm_seq_region_id` (`asm_seq_region_id`,`asm_start`)
......@@ -61,14 +61,14 @@ CREATE TABLE `assembly` (
CREATE TABLE `assembly_exception` (
`assembly_exception_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`seq_region_id` int(11) NOT NULL DEFAULT 0,
`seq_region_start` int(11) NOT NULL DEFAULT 0,
`seq_region_end` int(11) NOT NULL DEFAULT 0,
`seq_region_id` int(11) NOT NULL DEFAULT '0',
`seq_region_start` int(11) NOT NULL DEFAULT '0',
`seq_region_end` int(11) NOT NULL DEFAULT '0',
`exc_type` enum('HAP','PAR','PATCH_NOVEL','PATCH_FIX') COLLATE latin1_bin NOT NULL DEFAULT 'HAP',
`exc_seq_region_id` int(11) NOT NULL DEFAULT 0,
`exc_seq_region_start` int(11) NOT NULL DEFAULT 0,
`exc_seq_region_end` int(11) NOT NULL DEFAULT 0,
`ori` int(11) NOT NULL DEFAULT 0,
`exc_seq_region_id` int(11) NOT NULL DEFAULT '0',
`exc_seq_region_start` int(11) NOT NULL DEFAULT '0',
`exc_seq_region_end` int(11) NOT NULL DEFAULT '0',
`ori` int(11) NOT NULL DEFAULT '0',
PRIMARY KEY (`assembly_exception_id`),
KEY `sr_idx` (`seq_region_id`,`seq_region_start`),
KEY `ex_idx` (`exc_seq_region_id`,`exc_seq_region_start`)
......@@ -82,12 +82,12 @@ CREATE TABLE `associated_group` (
CREATE TABLE `associated_xref` (
`associated_xref_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`object_xref_id` int(10) unsigned NOT NULL DEFAULT 0,
`xref_id` int(10) unsigned NOT NULL DEFAULT 0,
`object_xref_id` int(10) unsigned NOT NULL DEFAULT '0',
`xref_id` int(10) unsigned NOT NULL DEFAULT '0',
`source_xref_id` int(10) unsigned DEFAULT NULL,
`condition_type` varchar(128) DEFAULT NULL,
`associated_group_id` int(10) unsigned DEFAULT NULL,
`rank` int(10) unsigned DEFAULT 0,
`rank` int(10) unsigned DEFAULT '0',
PRIMARY KEY (`associated_xref_id`),
UNIQUE KEY `object_associated_source_type_idx` (`object_xref_id`,`xref_id`,`source_xref_id`,`condition_type`,`associated_group_id`),
KEY `associated_source_idx` (`source_xref_id`),
......@@ -100,7 +100,7 @@ CREATE TABLE `attrib_type` (
`attrib_type_id` smallint(5) unsigned NOT NULL AUTO_INCREMENT,
`code` varchar(20) COLLATE latin1_bin NOT NULL DEFAULT '',
`name` varchar(255) COLLATE latin1_bin NOT NULL DEFAULT '',
`description` text COLLATE latin1_bin DEFAULT NULL,
`description` text COLLATE latin1_bin,
PRIMARY KEY (`attrib_type_id`),
UNIQUE KEY `code_idx` (`code`)
) ENGINE=MyISAM AUTO_INCREMENT=394 DEFAULT CHARSET=latin1 COLLATE=latin1_bin;
......@@ -111,7 +111,7 @@ CREATE TABLE `biotype` (
`object_type` enum('gene','transcript') NOT NULL DEFAULT 'gene',
`db_type` set('cdna','core','coreexpressionatlas','coreexpressionest','coreexpressiongnf','funcgen','otherfeatures','rnaseq','variation','vega','presite','sangervega') NOT NULL DEFAULT 'core',
`attrib_type_id` int(11) DEFAULT NULL,
`description` text DEFAULT NULL,
`description` text,
`biotype_group` enum('coding','pseudogene','snoncoding','lnoncoding','mnoncoding','LRG','undefined','no_group') DEFAULT NULL,
`so_acc` varchar(64) DEFAULT NULL,
`so_term` varchar(1023) DEFAULT NULL,
......@@ -121,7 +121,7 @@ CREATE TABLE `biotype` (
CREATE TABLE `coord_system` (
`coord_system_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`species_id` int(10) unsigned NOT NULL DEFAULT 1,
`species_id` int(10) unsigned NOT NULL DEFAULT '1',
`name` varchar(40) NOT NULL,
`version` varchar(255) DEFAULT NULL,
`rank` int(11) NOT NULL,
......@@ -137,9 +137,9 @@ CREATE TABLE `data_file` (
`coord_system_id` int(10) unsigned NOT NULL,
`analysis_id` smallint(5) unsigned NOT NULL,
`name` varchar(100) NOT NULL,
`version_lock` tinyint(1) NOT NULL DEFAULT 0,
`absolute` tinyint(1) NOT NULL DEFAULT 0,
`url` text DEFAULT NULL,
`version_lock` tinyint(1) NOT NULL DEFAULT '0',
`absolute` tinyint(1) NOT NULL DEFAULT '0',
`url` text,
`file_type` enum('BAM','BAMCOV','BIGBED','BIGWIG','VCF') DEFAULT NULL,
PRIMARY KEY (`data_file_id`),
UNIQUE KEY `df_unq_idx` (`coord_system_id`,`analysis_id`,`name`,`file_type`),
......@@ -149,11 +149,11 @@ CREATE TABLE `data_file` (
CREATE TABLE `density_feature` (
`density_feature_id` int(11) NOT NULL AUTO_INCREMENT,
`density_type_id` int(11) NOT NULL DEFAULT 0,
`seq_region_id` int(11) NOT NULL DEFAULT 0,
`seq_region_start` int(11) NOT NULL DEFAULT 0,
`seq_region_end` int(11) NOT NULL DEFAULT 0,
`density_value` float NOT NULL DEFAULT 0,
`density_type_id` int(11) NOT NULL DEFAULT '0',
`seq_region_id` int(11) NOT NULL DEFAULT '0',
`seq_region_start` int(11) NOT NULL DEFAULT '0',
`seq_region_end` int(11) NOT NULL DEFAULT '0',
`density_value` float NOT NULL DEFAULT '0',
PRIMARY KEY (`density_feature_id`),
KEY `seq_region_idx` (`density_type_id`,`seq_region_id`,`seq_region_start`),
KEY `seq_region_id_idx` (`seq_region_id`)
......@@ -161,9 +161,9 @@ CREATE TABLE `density_feature` (
CREATE TABLE `density_type` (
`density_type_id` int(11) NOT NULL AUTO_INCREMENT,
`analysis_id` int(11) NOT NULL DEFAULT 0,
`block_size` int(11) NOT NULL DEFAULT 0,
`region_features` int(11) NOT NULL DEFAULT 0,
`analysis_id` int(11) NOT NULL DEFAULT '0',
`block_size` int(11) NOT NULL DEFAULT '0',
`region_features` int(11) NOT NULL DEFAULT '0',
`value_type` enum('sum','ratio') COLLATE latin1_bin NOT NULL DEFAULT 'sum',
PRIMARY KEY (`density_type_id`),
UNIQUE KEY `analysis_id` (`analysis_id`,`block_size`,`region_features`)
......@@ -182,24 +182,24 @@ CREATE TABLE `ditag` (
`ditag_id` int(10) NOT NULL AUTO_INCREMENT,
`name` varchar(30) DEFAULT NULL,
`type` varchar(30) DEFAULT NULL,
`tag_count` smallint(6) DEFAULT 1,
`sequence` text DEFAULT NULL,
`tag_count` smallint(6) DEFAULT '1',
`sequence` text,
PRIMARY KEY (`ditag_id`)
) ENGINE=MyISAM AUTO_INCREMENT=3278361 DEFAULT CHARSET=latin1;
CREATE TABLE `ditag_feature` (
`ditag_feature_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`ditag_id` int(10) unsigned NOT NULL DEFAULT 0,
`ditag_pair_id` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_start` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_end` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_strand` tinyint(1) NOT NULL DEFAULT 0,
`analysis_id` int(10) unsigned NOT NULL DEFAULT 0,
`hit_start` int(10) unsigned NOT NULL DEFAULT 0,
`hit_end` int(10) unsigned NOT NULL DEFAULT 0,
`hit_strand` tinyint(1) NOT NULL DEFAULT 0,
`cigar_line` text DEFAULT NULL,
`ditag_id` int(10) unsigned NOT NULL DEFAULT '0',
`ditag_pair_id` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_id` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_start` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_end` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_strand` tinyint(1) NOT NULL DEFAULT '0',
`analysis_id` int(10) unsigned NOT NULL DEFAULT '0',
`hit_start` int(10) unsigned NOT NULL DEFAULT '0',
`hit_end` int(10) unsigned NOT NULL DEFAULT '0',
`hit_strand` tinyint(1) NOT NULL DEFAULT '0',
`cigar_line` text,
`ditag_side` char(1) DEFAULT '',
PRIMARY KEY (`ditag_feature_id`),
KEY `ditag_id` (`ditag_id`),
......@@ -208,26 +208,26 @@ CREATE TABLE `ditag_feature` (
) ENGINE=MyISAM AUTO_INCREMENT=4828765 DEFAULT CHARSET=latin1;
CREATE TABLE `dna` (
`seq_region_id` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT '0',
`sequence` mediumtext COLLATE latin1_bin NOT NULL,
PRIMARY KEY (`seq_region_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_bin MAX_ROWS=750000 AVG_ROW_LENGTH=19000;
CREATE TABLE `dna_align_feature` (
`dna_align_feature_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_start` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_end` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_strand` tinyint(1) NOT NULL DEFAULT 0,
`hit_start` int(11) NOT NULL DEFAULT 0,
`hit_end` int(11) NOT NULL DEFAULT 0,
`hit_strand` tinyint(1) NOT NULL DEFAULT 0,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_start` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_end` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_strand` tinyint(1) NOT NULL DEFAULT '0',
`hit_start` int(11) NOT NULL DEFAULT '0',
`hit_end` int(11) NOT NULL DEFAULT '0',
`hit_strand` tinyint(1) NOT NULL DEFAULT '0',
`hit_name` varchar(40) COLLATE latin1_bin NOT NULL DEFAULT '',
`analysis_id` int(10) unsigned NOT NULL DEFAULT 0,
`analysis_id` int(10) unsigned NOT NULL DEFAULT '0',
`score` double DEFAULT NULL,
`evalue` double DEFAULT NULL,
`perc_ident` float DEFAULT NULL,
`cigar_line` text COLLATE latin1_bin DEFAULT NULL,
`cigar_line` text COLLATE latin1_bin,
`external_db_id` smallint(5) unsigned DEFAULT NULL,
`hcoverage` double DEFAULT NULL,
`align_type` enum('ensembl','cigar','vulgar','mdtag') COLLATE latin1_bin DEFAULT 'ensembl',
......@@ -257,8 +257,8 @@ CREATE TABLE `exon` (
`seq_region_strand` tinyint(2) NOT NULL,
`phase` tinyint(2) NOT NULL,
`end_phase` tinyint(2) NOT NULL,
`is_current` tinyint(1) NOT NULL DEFAULT 1,
`is_constitutive` tinyint(1) NOT NULL DEFAULT 0,
`is_current` tinyint(1) NOT NULL DEFAULT '1',
`is_constitutive` tinyint(1) NOT NULL DEFAULT '0',
`stable_id` varchar(128) DEFAULT NULL,
`version` smallint(5) unsigned DEFAULT NULL,
`created_date` datetime DEFAULT NULL,
......@@ -269,31 +269,31 @@ CREATE TABLE `exon` (
) ENGINE=MyISAM AUTO_INCREMENT=162071 DEFAULT CHARSET=latin1;
CREATE TABLE `exon_transcript` (
`exon_id` int(10) unsigned NOT NULL DEFAULT 0,
`transcript_id` int(10) unsigned NOT NULL DEFAULT 0,
`rank` int(10) NOT NULL DEFAULT 0,
`exon_id` int(10) unsigned NOT NULL DEFAULT '0',
`transcript_id` int(10) unsigned NOT NULL DEFAULT '0',
`rank` int(10) NOT NULL DEFAULT '0',
PRIMARY KEY (`exon_id`,`transcript_id`,`rank`),
KEY `transcript` (`transcript_id`),
KEY `exon` (`exon_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_bin;
CREATE TABLE `external_db` (
`external_db_id` int(11) NOT NULL DEFAULT 0,
`external_db_id` int(11) NOT NULL DEFAULT '0',
`db_name` varchar(27) COLLATE latin1_bin NOT NULL DEFAULT '',
`db_release` varchar(40) COLLATE latin1_bin NOT NULL DEFAULT '',
`status` enum('KNOWNXREF','KNOWN','XREF','PRED','ORTH','PSEUDO') COLLATE latin1_bin NOT NULL DEFAULT 'KNOWNXREF',
`priority` int(11) NOT NULL DEFAULT 0,
`priority` int(11) NOT NULL DEFAULT '0',
`db_display_name` varchar(255) COLLATE latin1_bin DEFAULT NULL,
`type` enum('ARRAY','ALT_TRANS','ALT_GENE','MISC','LIT','PRIMARY_DB_SYNONYM','ENSEMBL') COLLATE latin1_bin NOT NULL,
`secondary_db_name` varchar(255) COLLATE latin1_bin DEFAULT NULL,
`secondary_db_table` varchar(255) COLLATE latin1_bin DEFAULT NULL,
`description` text COLLATE latin1_bin DEFAULT NULL,
`description` text COLLATE latin1_bin,
PRIMARY KEY (`external_db_id`),
UNIQUE KEY `db_name_db_release_idx` (`db_name`,`db_release`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_bin;
CREATE TABLE `external_synonym` (
`xref_id` int(10) unsigned NOT NULL DEFAULT 0,
`xref_id` int(10) unsigned NOT NULL DEFAULT '0',
`synonym` varchar(40) COLLATE latin1_bin NOT NULL DEFAULT '',
PRIMARY KEY (`xref_id`,`synonym`),
KEY `name_index` (`synonym`)
......@@ -309,8 +309,8 @@ CREATE TABLE `gene` (
`seq_region_strand` tinyint(2) NOT NULL,
`display_xref_id` int(10) unsigned DEFAULT NULL,
`source` varchar(40) NOT NULL,
`description` text DEFAULT NULL,
`is_current` tinyint(1) NOT NULL DEFAULT 1,
`description` text,
`is_current` tinyint(1) NOT NULL DEFAULT '1',
`canonical_transcript_id` int(10) unsigned NOT NULL,
`stable_id` varchar(128) DEFAULT NULL,
`version` smallint(5) unsigned DEFAULT NULL,
......@@ -326,13 +326,13 @@ CREATE TABLE `gene` (
CREATE TABLE `gene_archive` (
`gene_stable_id` varchar(128) COLLATE latin1_bin NOT NULL DEFAULT '',
`gene_version` smallint(6) NOT NULL DEFAULT 0,
`gene_version` smallint(6) NOT NULL DEFAULT '0',
`transcript_stable_id` varchar(128) COLLATE latin1_bin NOT NULL DEFAULT '',
`transcript_version` smallint(6) NOT NULL DEFAULT 0,
`transcript_version` smallint(6) NOT NULL DEFAULT '0',
`translation_stable_id` varchar(128) COLLATE latin1_bin NOT NULL DEFAULT '',
`translation_version` smallint(6) NOT NULL DEFAULT 0,
`peptide_archive_id` int(11) NOT NULL DEFAULT 0,
`mapping_session_id` int(11) NOT NULL DEFAULT 0,
`translation_version` smallint(6) NOT NULL DEFAULT '0',
`peptide_archive_id` int(11) NOT NULL DEFAULT '0',
`mapping_session_id` int(11) NOT NULL DEFAULT '0',
KEY `gene_idx` (`gene_stable_id`,`gene_version`),
KEY `transcript_idx` (`transcript_stable_id`,`transcript_version`),
KEY `translation_idx` (`translation_stable_id`,`translation_version`),
......@@ -340,8 +340,8 @@ CREATE TABLE `gene_archive` (
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_bin;
CREATE TABLE `gene_attrib` (
`gene_id` int(10) unsigned NOT NULL DEFAULT 0,
`attrib_type_id` smallint(5) unsigned NOT NULL DEFAULT 0,
`gene_id` int(10) unsigned NOT NULL DEFAULT '0',
`attrib_type_id` smallint(5) unsigned NOT NULL DEFAULT '0',
`value` text COLLATE latin1_bin NOT NULL,
UNIQUE KEY `gene_attribx` (`gene_id`,`attrib_type_id`,`value`(500)),
KEY `type_val_idx` (`attrib_type_id`,`value`(40)),
......@@ -352,8 +352,8 @@ CREATE TABLE `gene_attrib` (
CREATE TABLE `genome_statistics` (
`genome_statistics_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`statistic` varchar(128) NOT NULL,
`value` bigint(11) unsigned NOT NULL DEFAULT 0,
`species_id` int(10) unsigned DEFAULT 1,
`value` bigint(11) unsigned NOT NULL DEFAULT '0',
`species_id` int(10) unsigned DEFAULT '1',
`attrib_type_id` int(10) unsigned DEFAULT NULL,
`timestamp` datetime DEFAULT NULL,
PRIMARY KEY (`genome_statistics_id`),
......@@ -361,14 +361,14 @@ CREATE TABLE `genome_statistics` (
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
CREATE TABLE `identity_xref` (
`object_xref_id` int(10) unsigned NOT NULL DEFAULT 0,
`object_xref_id` int(10) unsigned NOT NULL DEFAULT '0',
`xref_identity` int(5) DEFAULT NULL,
`ensembl_identity` int(5) DEFAULT NULL,
`xref_start` int(11) DEFAULT NULL,
`xref_end` int(11) DEFAULT NULL,
`ensembl_start` int(11) DEFAULT NULL,
`ensembl_end` int(11) DEFAULT NULL,
`cigar_line` text COLLATE latin1_bin DEFAULT NULL,
`cigar_line` text COLLATE latin1_bin,
`score` double DEFAULT NULL,
`evalue` double DEFAULT NULL,
PRIMARY KEY (`object_xref_id`)
......@@ -391,7 +391,7 @@ CREATE TABLE `intron_supporting_evidence` (
`hit_name` varchar(100) NOT NULL,
`score` decimal(10,3) DEFAULT NULL,
`score_type` enum('NONE','DEPTH') DEFAULT 'NONE',
`is_splice_canonical` tinyint(1) NOT NULL DEFAULT 0,
`is_splice_canonical` tinyint(1) NOT NULL DEFAULT '0',
PRIMARY KEY (`intron_supporting_evidence_id`),
UNIQUE KEY `analysis_id` (`analysis_id`,`seq_region_id`,`seq_region_start`,`seq_region_end`,`seq_region_strand`,`hit_name`),
KEY `seq_region_idx` (`seq_region_id`,`seq_region_start`)
......@@ -399,9 +399,9 @@ CREATE TABLE `intron_supporting_evidence` (
CREATE TABLE `karyotype` (
`karyotype_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_start` int(10) NOT NULL DEFAULT 0,
`seq_region_end` int(10) NOT NULL DEFAULT 0,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_start` int(10) NOT NULL DEFAULT '0',
`seq_region_end` int(10) NOT NULL DEFAULT '0',
`band` varchar(40) COLLATE latin1_bin DEFAULT NULL,
`stain` varchar(40) COLLATE latin1_bin DEFAULT NULL,
PRIMARY KEY (`karyotype_id`),
......@@ -420,8 +420,8 @@ CREATE TABLE `mapping_session` (
`new_db_name` varchar(80) COLLATE latin1_bin NOT NULL DEFAULT '',
`old_release` varchar(5) COLLATE latin1_bin NOT NULL DEFAULT '',
`new_release` varchar(5) COLLATE latin1_bin NOT NULL DEFAULT '',
`old_assembly` varchar(20) COLLATE latin1_bin NOT NULL DEFAULT '',
`new_assembly` varchar(20) COLLATE latin1_bin NOT NULL DEFAULT '',
`old_assembly` varchar(80) COLLATE latin1_bin NOT NULL DEFAULT '',
`new_assembly` varchar(80) COLLATE latin1_bin NOT NULL DEFAULT '',
`created` datetime DEFAULT NULL,
PRIMARY KEY (`mapping_session_id`)
) ENGINE=MyISAM AUTO_INCREMENT=4 DEFAULT CHARSET=latin1 COLLATE=latin1_bin;
......@@ -439,8 +439,8 @@ CREATE TABLE `marker` (
`display_marker_synonym_id` int(10) unsigned DEFAULT NULL,
`left_primer` varchar(100) COLLATE latin1_bin NOT NULL DEFAULT '',
`right_primer` varchar(100) COLLATE latin1_bin NOT NULL DEFAULT '',
`min_primer_dist` int(10) unsigned NOT NULL DEFAULT 0,
`max_primer_dist` int(10) unsigned NOT NULL DEFAULT 0,
`min_primer_dist` int(10) unsigned NOT NULL DEFAULT '0',
`max_primer_dist` int(10) unsigned NOT NULL DEFAULT '0',
`priority` int(11) DEFAULT NULL,
`type` enum('est','microsatellite') COLLATE latin1_bin DEFAULT NULL,
PRIMARY KEY (`marker_id`),
......@@ -450,11 +450,11 @@ CREATE TABLE `marker` (
CREATE TABLE `marker_feature` (
`marker_feature_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`marker_id` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_start` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_end` int(10) unsigned NOT NULL DEFAULT 0,
`analysis_id` int(10) unsigned NOT NULL DEFAULT 0,
`marker_id` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_id` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_start` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_end` int(10) unsigned NOT NULL DEFAULT '0',
`analysis_id` int(10) unsigned NOT NULL DEFAULT '0',
`map_weight` int(10) unsigned DEFAULT NULL,
PRIMARY KEY (`marker_feature_id`),
KEY `seq_region_idx` (`seq_region_id`,`seq_region_start`),
......@@ -462,10 +462,10 @@ CREATE TABLE `marker_feature` (
) ENGINE=MyISAM AUTO_INCREMENT=103 DEFAULT CHARSET=latin1 COLLATE=latin1_bin;
CREATE TABLE `marker_map_location` (
`marker_id` int(10) unsigned NOT NULL DEFAULT 0,
`map_id` int(10) unsigned NOT NULL DEFAULT 0,
`marker_id` int(10) unsigned NOT NULL DEFAULT '0',
`map_id` int(10) unsigned NOT NULL DEFAULT '0',
`chromosome_name` varchar(15) COLLATE latin1_bin NOT NULL DEFAULT '',
`marker_synonym_id` int(10) unsigned NOT NULL DEFAULT 0,
`marker_synonym_id` int(10) unsigned NOT NULL DEFAULT '0',
`position` varchar(15) COLLATE latin1_bin NOT NULL DEFAULT '',
`lod_score` double DEFAULT NULL,
PRIMARY KEY (`marker_id`,`map_id`),
......@@ -474,7 +474,7 @@ CREATE TABLE `marker_map_location` (
CREATE TABLE `marker_synonym` (
`marker_synonym_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`marker_id` int(10) unsigned NOT NULL DEFAULT 0,
`marker_id` int(10) unsigned NOT NULL DEFAULT '0',
`source` varchar(20) COLLATE latin1_bin DEFAULT NULL,
`name` varchar(30) COLLATE latin1_bin DEFAULT NULL,
PRIMARY KEY (`marker_synonym_id`),
......@@ -484,24 +484,24 @@ CREATE TABLE `marker_synonym` (
CREATE TABLE `meta` (
`meta_id` int(11) NOT NULL AUTO_INCREMENT,
`species_id` int(10) unsigned DEFAULT 1,
`species_id` int(10) unsigned DEFAULT '1',
`meta_key` varchar(40) NOT NULL,
`meta_value` varchar(255) NOT NULL,
PRIMARY KEY (`meta_id`),
UNIQUE KEY `species_key_value_idx` (`species_id`,`meta_key`,`meta_value`),
KEY `species_value_idx` (`species_id`,`meta_value`)
) ENGINE=MyISAM AUTO_INCREMENT=191 DEFAULT CHARSET=latin1;
) ENGINE=MyISAM AUTO_INCREMENT=193 DEFAULT CHARSET=latin1;
CREATE TABLE `meta_coord` (
`table_name` varchar(40) COLLATE latin1_bin NOT NULL DEFAULT '',
`coord_system_id` int(11) NOT NULL DEFAULT 0,
`coord_system_id` int(11) NOT NULL DEFAULT '0',
`max_length` int(11) DEFAULT NULL,
UNIQUE KEY `cs_table_name_idx` (`coord_system_id`,`table_name`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_bin;
CREATE TABLE `misc_attrib` (
`misc_feature_id` int(10) unsigned NOT NULL DEFAULT 0,
`attrib_type_id` smallint(5) unsigned NOT NULL DEFAULT 0,
`misc_feature_id` int(10) unsigned NOT NULL DEFAULT '0',
`attrib_type_id` smallint(5) unsigned NOT NULL DEFAULT '0',
`value` text COLLATE latin1_bin NOT NULL,
UNIQUE KEY `misc_attribx` (`misc_feature_id`,`attrib_type_id`,`value`(500)),
KEY `type_val_idx` (`attrib_type_id`,`value`(40)),
......@@ -511,17 +511,17 @@ CREATE TABLE `misc_attrib` (
CREATE TABLE `misc_feature` (
`misc_feature_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_start` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_end` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_strand` tinyint(4) NOT NULL DEFAULT 0,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_start` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_end` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_strand` tinyint(4) NOT NULL DEFAULT '0',
PRIMARY KEY (`misc_feature_id`),
KEY `seq_region_idx` (`seq_region_id`,`seq_region_start`)
) ENGINE=MyISAM AUTO_INCREMENT=12 DEFAULT CHARSET=latin1 COLLATE=latin1_bin;
CREATE TABLE `misc_feature_misc_set` (
`misc_feature_id` int(10) unsigned NOT NULL DEFAULT 0,
`misc_set_id` smallint(5) unsigned NOT NULL DEFAULT 0,
`misc_feature_id` int(10) unsigned NOT NULL DEFAULT '0',
`misc_set_id` smallint(5) unsigned NOT NULL DEFAULT '0',
PRIMARY KEY (`misc_feature_id`,`misc_set_id`),
KEY `reverse_idx` (`misc_set_id`,`misc_feature_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_bin;
......@@ -531,14 +531,14 @@ CREATE TABLE `misc_set` (
`code` varchar(25) COLLATE latin1_bin NOT NULL DEFAULT '',
`name` varchar(255) COLLATE latin1_bin NOT NULL DEFAULT '',
`description` text COLLATE latin1_bin NOT NULL,
`max_length` int(10) unsigned NOT NULL DEFAULT 0,
`max_length` int(10) unsigned NOT NULL DEFAULT '0',
PRIMARY KEY (`misc_set_id`),
UNIQUE KEY `code_idx` (`code`)
) ENGINE=MyISAM AUTO_INCREMENT=13 DEFAULT CHARSET=latin1 COLLATE=latin1_bin;
CREATE TABLE `object_xref` (
`object_xref_id` int(11) NOT NULL AUTO_INCREMENT,
`ensembl_id` int(10) unsigned NOT NULL DEFAULT 0,
`ensembl_id` int(10) unsigned NOT NULL DEFAULT '0',
`ensembl_object_type` enum('RawContig','Transcript','Gene','Translation','Operon','OperonTranscript','Marker','RNAProduct') COLLATE latin1_bin NOT NULL,
`xref_id` int(10) unsigned NOT NULL,
`linkage_annotation` varchar(255) COLLATE latin1_bin DEFAULT NULL,
......@@ -550,7 +550,7 @@ CREATE TABLE `object_xref` (
) ENGINE=MyISAM AUTO_INCREMENT=1000011 DEFAULT CHARSET=latin1 COLLATE=latin1_bin;
CREATE TABLE `ontology_xref` (
`object_xref_id` int(10) unsigned NOT NULL DEFAULT 0,
`object_xref_id` int(10) unsigned NOT NULL DEFAULT '0',
`linkage_type` varchar(3) DEFAULT NULL,
`source_xref_id` int(10) unsigned DEFAULT NULL,
UNIQUE KEY `object_source_type_idx` (`object_xref_id`,`source_xref_id`,`linkage_type`),
......@@ -611,13 +611,13 @@ CREATE TABLE `peptide_archive` (
CREATE TABLE `prediction_exon` (
`prediction_exon_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`prediction_transcript_id` int(10) unsigned NOT NULL DEFAULT 0,
`exon_rank` smallint(5) unsigned NOT NULL DEFAULT 0,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_start` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_end` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_strand` tinyint(4) NOT NULL DEFAULT 0,
`start_phase` tinyint(4) NOT NULL DEFAULT 0,
`prediction_transcript_id` int(10) unsigned NOT NULL DEFAULT '0',
`exon_rank` smallint(5) unsigned NOT NULL DEFAULT '0',
`seq_region_id` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_start` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_end` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_strand` tinyint(4) NOT NULL DEFAULT '0',
`start_phase` tinyint(4) NOT NULL DEFAULT '0',
`score` double DEFAULT NULL,
`p_value` double DEFAULT NULL,
PRIMARY KEY (`prediction_exon_id`),
......@@ -627,10 +627,10 @@ CREATE TABLE `prediction_exon` (
CREATE TABLE `prediction_transcript` (
`prediction_transcript_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_start` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_end` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_strand` tinyint(4) NOT NULL DEFAULT 0,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_start` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_end` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_strand` tinyint(4) NOT NULL DEFAULT '0',
`analysis_id` int(11) DEFAULT NULL,
`display_label` varchar(255) COLLATE latin1_bin DEFAULT NULL,
PRIMARY KEY (`prediction_transcript_id`),
......@@ -640,18 +640,18 @@ CREATE TABLE `prediction_transcript` (
CREATE TABLE `protein_align_feature` (
`protein_align_feature_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_start` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_end` int(10) unsigned NOT NULL DEFAULT 0,
`seq_region_strand` tinyint(1) NOT NULL DEFAULT 1,
`hit_start` int(10) NOT NULL DEFAULT 0,
`hit_end` int(10) NOT NULL DEFAULT 0,
`seq_region_id` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_start` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_end` int(10) unsigned NOT NULL DEFAULT '0',
`seq_region_strand` tinyint(1) NOT NULL DEFAULT '1',
`hit_start` int(10) NOT NULL DEFAULT '0',
`hit_end` int(10) NOT NULL DEFAULT '0',
`hit_name` varchar(40) COLLATE latin1_bin NOT NULL DEFAULT '',
`analysis_id` int(10) unsigned NOT NULL DEFAULT 0,
`analysis_id` int(10) unsigned NOT NULL DEFAULT '0',
`score` double DEFAULT NULL,
`evalue` double DEFAULT NULL,
`perc_ident` float DEFAULT NULL,
`cigar_line` text COLLATE latin1_bin DEFAULT NULL,
`cigar_line` text COLLATE latin1_bin,
`external_db_id` smallint(5) unsigned DEFAULT NULL,
`hcoverage` double DEFAULT NULL,
`align_type` enum('ensembl','cigar','vulgar','mdtag') COLLATE latin1_bin DEFAULT 'ensembl',
......@@ -665,19 +665,19 @@ CREATE TABLE `protein_align_feature` (
CREATE TABLE `protein_feature` (
`protein_feature_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`translation_id` int(11) NOT NULL DEFAULT 0,
`seq_start` int(10) NOT NULL DEFAULT 0,
`seq_end` int(10) NOT NULL DEFAULT 0,
`hit_start` int(10) NOT NULL DEFAULT 0,
`hit_end` int(10) NOT NULL DEFAULT 0,
`translation_id` int(11) NOT NULL DEFAULT '0',
`seq_start` int(10) NOT NULL DEFAULT '0',
`seq_end` int(10) NOT NULL DEFAULT '0',
`hit_start` int(10) NOT NULL DEFAULT '0',
`hit_end` int(10) NOT NULL DEFAULT '0',