Does anyone know how to work-around this exception
at /n/site/inst/shared/sys/lib/perl5/site_perl/5.8.8/Exception/Class.pm line
269
Exception::Class::Base::throw('BioMart::Exception::Configuration',
'Attribute \'gene_exon_intron\' not found in dataset default.m...') called at
/n/site/inst/shared/bioinfo/ensembl/biomart-perl/release-0_7/lib//BioMart/Registry.pm
line 490
I'm querying with perl api (/ensembl/biomart-perl/release-0_7 ) using code
exported from biomart/ensembl from dec2008
Below is a URL to the query, which works interactively, followed by (slightly
editted) perl code exported upon clicking the "perl" button
Thanks for your help....
--Malcolm Cook
http://dec2008.archive.ensembl.org/biomart/martview/f26d676eafa1feaf994ca31a18fcadf0/f26d676eafa1feaf994ca31a18fcadf0/f26d676eafa1feaf994ca31a18fcadf0?VIRTUALSCHEMANAME=default&ATTRIBUTES=mmusculus_gene_ensembl.default.sequences.ensembl_gene_id|mmusculus_gene_ensembl.default.sequences.gene_exon_intron|mmusculus_gene_ensembl.default.sequences.chromosome_name|mmusculus_gene_ensembl.default.sequences.strand|mmusculus_gene_ensembl.default.sequences.start_position|mmusculus_gene_ensembl.default.sequences.end_position&FILTERS=mmusculus_gene_ensembl.default.filters.ensembl_gene_id."ENSMUSG00000083773,ENSMUSG00000081262,ENSMUSG00000082711"&VISIBLEPANEL=filterpanel
#!/bin/env perl
# An example script demonstrating the use of BioMart API.
# This perl API representation is only available for configuration versions >=
0.5
use strict;
use BioMart::Initializer;
use BioMart::Query;
use BioMart::QueryRunner;
my $confFile = #"PATH TO YOUR REGISTRY FILE UNDER biomart-perl/conf/. For
Biomart Central Registry navigate to
# "http://www.biomart.org/biomart/martservice?type=registry"
"/n/site/inst/shared/bioinfo/ensembl/biomart-perl/release-0_7/conf/registryURLPointer.xml"
;
#
# NB: change action to 'clean' if you wish to start a fresh configuration
# and to 'cached' if you want to skip configuration step on subsequent runs
from the same registry
#
my $action='cached';
my $initializer = BioMart::Initializer->new('registryFile'=>$confFile,
'action'=>$action);
my $registry = $initializer->getRegistry;
my $query =
BioMart::Query->new('registry'=>$registry,'virtualSchemaName'=>'default');
$query->setDataset("mmusculus_gene_ensembl");
$query->addFilter("ensembl_gene_id",
["ENSMUSG00000083773","ENSMUSG00000081262","ENSMUSG00000082711"]);
$query->addAttribute("ensembl_gene_id");
$query->addAttribute("gene_exon_intron");
$query->addAttribute("chromosome_name");
$query->addAttribute("strand");
$query->addAttribute("start_position");
$query->addAttribute("end_position");
$query->formatter("FASTA");
my $query_runner = BioMart::QueryRunner->new();
$query_runner->execute($query);
$query_runner->printResults();