ensembl-hive  2.7.0
HomoSapiens.pm
Go to the documentation of this file.
1 =head1 LICENSE
2 
3 See the NOTICE file distributed with this work for additional information
4 regarding copyright ownership.
5 
6 Licensed under the Apache License, Version 2.0 (the "License");
7 you may not use this file except in compliance with the License.
8 You may obtain a copy of the License at
9 
10  http://www.apache.org/licenses/LICENSE-2.0
11 
12 Unless required by applicable law or agreed to in writing, software
13 distributed under the License is distributed on an "AS IS" BASIS,
14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 See the License for the specific language governing permissions and
16 limitations under the License.
17 
18 =cut
19 
20 
21 use strict;
22 use warnings;
23 
24 package SeqStoreConverter::HomoSapiens;
25 
27 
28 use vars qw(@ISA);
29 
31 
32 
33 sub create_attribs {
34  my $self = shift;
35 
36  #
37  # Human clones need their htg phase information copied
38  #
39 
40  my $source = $self->source();
41  my $target = $self->target();
42  my $dbh = $self->dbh();
43 
44  $self->SUPER::create_attribs();
45 
46  $self->debug("HomoSapiens specific: Creating HTG Phase seq_region attribs");
47 
48  $dbh->do
49  ("INSERT INTO $target.attrib_type( code, name, description ) " .
50  "VALUES ('htg_phase', 'HTG Phase', 'High Throughput Genome Phase')");
51 
52 
53  $dbh->do
54  ("INSERT INTO $target.seq_region_attrib( seq_region_id, attrib_type_id, " .
55  "value) " .
56  "SELECT tmp_cln.new_id, attrib_type.attrib_type_id, cln.htg_phase " .
57  "FROM $target.tmp_cln_map tmp_cln, $target.attrib_type attrib_type, " .
58  " $source.clone cln " .
59  "WHERE cln.clone_id = tmp_cln.old_id " .
60  "AND attrib_type.code = 'htg_phase'");
61 
62  return;
63 }
64 
65 
66 1;
SeqStoreConverter::BasicConverter
Definition: BasicConverter.pm:3