Mercurial > repos > mahtabm > ensembl
annotate variant_effect_predictor/Bio/EnsEMBL/Variation/Pipeline/RebuildIndexes.pm @ 2:a5976b2dce6f
changing defualt values for ensembl database
author | mahtabm |
---|---|
date | Thu, 11 Apr 2013 17:15:42 +1000 |
parents | 1f6dce3d34e0 |
children |
rev | line source |
---|---|
0 | 1 package Bio::EnsEMBL::Variation::Pipeline::RebuildIndexes; |
2 | |
3 use strict; | |
4 use warnings; | |
5 | |
6 use base qw(Bio::EnsEMBL::Variation::Pipeline::BaseVariationProcess); | |
7 | |
8 sub run { | |
9 | |
10 my $self = shift; | |
11 | |
12 my $tables = $self->param('tables'); | |
13 | |
14 my $var_dba = $self->get_species_adaptor('variation'); | |
15 | |
16 my $dbc = $var_dba->dbc; | |
17 | |
18 for my $table (@$tables) { | |
19 $dbc->do("ALTER TABLE $table ENABLE KEYS") | |
20 or warn "Failed to enable keys on $table"; | |
21 } | |
22 } | |
23 | |
24 1; | |
25 |