[BioSQL-l] Rank terms

Hilmar Lapp hlapp at gnf.org
Wed Jan 26 14:42:32 EST 2005


Bioperl-db carries through the rank on persistent objects, including 
generating it corresponding to array index if it isn't set yet. It 
therefore also pulls it out of the database.

I was trying to find the code though that would *order* retrieved 
associations by rank, and as I recalled there isn't any, unless I'm 
maybe overlooking something. The reason you're getting the annotation 
or features back in the same order as loaded is most likely due to the 
fact that in the absence of joins and explicit ORDER BYs you get the 
rows either in the same order they were inserted into the DB, or in the 
order imposed by the unique key constraint or other index that 
supported the search. It depends on the RDBMS; I have seen that MySQL 
will at least most of the time do the former, whereas Oracle will do 
the latter. Either way, you'll get your annotation and feature arrays 
in the right order.

It would certainly be good to make the ordering explicit, but I recall 
that that's one of those things I've always wanted to add and never 
found the time to. Volunteers of course greatly welcome :-)

	-hilmar

On Jan 26, 2005, at 3:40 AM, Marc Logghe wrote:

>
>> biojava-live currently refer to it which suggests it is
>> usually entirely
>> ignored.
> I don't think this is the case. All this is handled _implicitely_ by 
> the different Adaptor modules.
> I don't really know the inners, but I only can notice that when you 
> fetch an entry using bioentry2flat.pl, the genbank record comes out, 
> in the exact way as you have loaded it into biosql. Features, 
> annotations, references come out in the exact same order. And the most 
> important line in bioentry2flat.pl is only
> $seq = $seqadaptor->find_by_unique_key($seq);
> So the rank must be used somewhere, sometime.
> my 0.02 $
>
> Cheers,
> Marc
>
> _______________________________________________
> BioSQL-l mailing list
> BioSQL-l at open-bio.org
> http://open-bio.org/mailman/listinfo/biosql-l
>
-- 
-------------------------------------------------------------
Hilmar Lapp                            email: lapp at gnf.org
GNF, San Diego, Ca. 92121              phone: +1-858-812-1757
-------------------------------------------------------------



More information about the BioSQL-l mailing list