[ensembl-dev] DBEntry fetch_all() call dies

Andy Yates ayates at ebi.ac.uk
Mon Mar 4 09:43:46 GMT 2013

Hi Nicole,

You seem to be suffering from a lot of DBEntryAdaptor woes. fetch_all() is a bit of a red herring of a method in this class. It is inherited from Bio::EnsEMBL::DBSQL::BaseAdaptor but only works when a number of internal stub-methods are implemented such as _tables(), _columns() and _objs_from_sth() in the extending class. All Ensembl adaptors inherit from BaseAdaptor but not all implement these internal methods; DBEntryAdaptor is one of these special cases so fetch_all() fails. The same would be true if you tried to use generic_fetch().

Hope this explains the issue a little bit more.

Best regards,


Andrew Yates                   Ensembl Core Software Project Leader
EMBL-EBI                       Tel: +44-(0)1223-492538
Wellcome Trust Genome Campus   Fax: +44-(0)1223-494468
Cambridge CB10 1SD, UK         http://www.ensembl.org/

On 1 Mar 2013, at 21:58, Nicole Washington <nlwashington at lbl.gov> wrote:

> Hi ENSEMBL API dev team,
> I've done a simple call to fetch all DBEntries via a DBEntryAdaptor object:
> my $species='homo_sapiens';
> my $dbentry_adaptor =$registry->get_adaptor($species, 'Core', 'DBEntry' );
> print STDOUT Dumper($dbentry_adaptor->fetch_all());
> And I get the following error output, dying at the line of the fetch_all call.
> -------------------- EXCEPTION --------------------
> MSG: abstract method _tables not defined by implementing subclass of BaseAdaptor
> STACK Bio::EnsEMBL::DBSQL::BaseAdaptor::_tables /Users/Nicole/src/ensembl/modules/Bio/EnsEMBL/DBSQL/BaseAdaptor.pm:819
> STACK Bio::EnsEMBL::DBSQL::BaseAdaptor::_generate_sql /Users/Nicole/src/ensembl/modules/Bio/EnsEMBL/DBSQL/BaseAdaptor.pm:455
> STACK Bio::EnsEMBL::DBSQL::BaseAdaptor::generic_fetch /Users/Nicole/src/ensembl/modules/Bio/EnsEMBL/DBSQL/BaseAdaptor.pm:409
> STACK Bio::EnsEMBL::DBSQL::BaseAdaptor::fetch_all /Users/Nicole/src/ensembl/modules/Bio/EnsEMBL/DBSQL/BaseAdaptor.pm:710
> STACK toplevel get_all_ensembl_genes.pl:117
> Date (localtime)    = Fri Mar  1 13:48:54 2013
> Ensembl API version = 70
> Are there any patches available?
> Nicole
> _______________________________________________
> Dev mailing list    Dev at ensembl.org
> Posting guidelines and subscribe/unsubscribe info: http://lists.ensembl.org/mailman/listinfo/dev
> Ensembl Blog: http://www.ensembl.info/

More information about the Dev mailing list