[Bioperl-guts-l] [15137] bioperl-live/trunk/Bio/DB/SeqFeature: added simple feature deletion script
Lincoln Stein
lstein at dev.open-bio.org
Wed Dec 10 13:26:31 EST 2008
Revision: 15137
Author: lstein
Date: 2008-12-10 13:26:31 -0500 (Wed, 10 Dec 2008)
Log Message:
-----------
added simple feature deletion script
Modified Paths:
--------------
bioperl-live/trunk/Bio/DB/SeqFeature/Store/DBI/mysql.pm
bioperl-live/trunk/Bio/DB/SeqFeature/Store.pm
Modified: bioperl-live/trunk/Bio/DB/SeqFeature/Store/DBI/mysql.pm
===================================================================
--- bioperl-live/trunk/Bio/DB/SeqFeature/Store/DBI/mysql.pm 2008-12-10 16:52:17 UTC (rev 15136)
+++ bioperl-live/trunk/Bio/DB/SeqFeature/Store/DBI/mysql.pm 2008-12-10 18:26:31 UTC (rev 15137)
@@ -1181,7 +1181,7 @@
$sth2->execute($cid);
my ($count) = $sth2->fetchrow_array;
if ($count == 1) {
- $self->_deleteid($cid) || $self->throw("Couldn't remove subfeature!");
+ $self->_deleteid($cid) || warn "An error occurred while removing subfeature id=$cid. Perhaps it was previously deleted?\n";
}
}
for my $table ($self->all_tables) {
Modified: bioperl-live/trunk/Bio/DB/SeqFeature/Store.pm
===================================================================
--- bioperl-live/trunk/Bio/DB/SeqFeature/Store.pm 2008-12-10 16:52:17 UTC (rev 15136)
+++ bioperl-live/trunk/Bio/DB/SeqFeature/Store.pm 2008-12-10 18:26:31 UTC (rev 15137)
@@ -43,7 +43,7 @@
@features = $db->get_features_by_alias('sma-3');
# ...by type
- @features = $db->get_features_by_name('gene');
+ @features = $db->get_features_by_type('gene');
# ...by location
@features = $db->get_features_by_location(-seq_id=>'Chr1',-start=>4000,-end=>600000);
More information about the Bioperl-guts-l
mailing list