Hi Matthias
I have tested your code all you need to do is to remove the following
three lines which are only for retrieving count
        $query->count(1); 
        $query_runner->execute($query); 
        print $query_runner->getCount(); 

Count, in case of Genomic sequence data has some problem, which we will
address soon. In addition, the two sections (one for count and one for
data retrievel are mutually exclusive - you can execute only one at a
time.)

hope this will get you going with your work for now.

cheers
syed


On Fri, 2007-08-24 at 12:43 -0500, Wahl, Matthias wrote:
> Hi All,
> 
> I am trying to retrieve pairwise genomic alignments from EnsMart using
> the script below (taken from the web page), but all I get the
> following error message:
> 
> Unimplemented method 'BioMart::Dataset::GenomicSequence::getCount'
> 
> Does anyone know what I am doing wrong?  
> Thanks,
> 
> Matthias
> 
> 
> 
> 
> 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("compara_mart_blastznet_hsap_mmus"); 
>         $query->addFilter("mmus_dnafrag_start", ["1"]); 
>         $query->addFilter("mmus_chro", ["1"]); 
>         $query->addFilter("mmus_dnafrag_end", ["10000000"]); 
>         $query->addAttribute("pairwise_genomic_alignments");
> 
> my $query_runner = BioMart::QueryRunner->new(); 
> ############################## GET COUNT ############################ 
>  $query->count(1); 
>  $query_runner->execute($query); 
>  print $query_runner->getCount(); 
> #####################################################################
> 
> 
> ############################## GET RESULTS ########################## 
> # to obtain unique rows only 
> # $query_runner->uniqueRowsOnly(1);
> 
> $query_runner->execute($query); 
> $query_runner->printHeader(); 
> $query_runner->printResults(); 
> $query_runner->printFooter(); 
> #####################################################################
> 
> Matthias Wahl, PhD 
> Stowers Institute for Medical Research 
> 1000 E. 50th Street 
> Kansas City, MO  64110 
> Phone:  816-926-4302 
> Fax: 816-926-2044 
> E-mail : [EMAIL PROTECTED] 
> http://www.stowers-institute.org/
> 

Reply via email to