From ekabore at irisa.fr Wed Dec 3 08:04:46 2003 From: ekabore at irisa.fr (Esther Kabore) Date: Wed Dec 3 08:11:01 2003 Subject: [BioSQL-l] Troubles with load_seqdatabase.pl References: <200311141633.hAEGXScm024011@portal.open-bio.org> Message-ID: <3FCDDF6E.3080102@irisa.fr> Hi, when trying to load data in my PostgreS database through load-seqdatabase.pl, I get this error message: Can't locate object method "category" via package "Bio::Annotation::OntologyTerm" at /local/lib/perl5/site_perl/5.8.0/Bio/DB/Persistent/PersistentObject.pm line 488, line 1015. I use --lookup and --safe options. Thank you for helping me. Esther From hlapp at gnf.org Wed Dec 3 20:10:45 2003 From: hlapp at gnf.org (Hilmar Lapp) Date: Wed Dec 3 20:17:05 2003 Subject: [BioSQL-l] Troubles with load_seqdatabase.pl Message-ID: <833E32F61B9F8746878F2A1865BECE60430997@EXCHCLUSTER01.lj.gnf.org> This sounds like a bioperl version mismatch problem. Which version of bioperl are you running? You'll need at least 1.2.3 installed. -hilmar > -----Original Message----- > From: Esther Kabore [mailto:ekabore@irisa.fr] > Sent: Wednesday, December 03, 2003 5:05 AM > To: biosql-l@portal.open-bio.org > Subject: [BioSQL-l] Troubles with load_seqdatabase.pl > > > > Hi, > when trying to load data in my PostgreS database through > load-seqdatabase.pl, I get this error message: > > Can't locate object method "category" via package > "Bio::Annotation::OntologyTerm" at > /local/lib/perl5/site_perl/5.8.0/Bio/DB/Persistent/PersistentO > bject.pm line 488, line 1015. > > I use --lookup and --safe options. > Thank you for helping me. > Esther > > _______________________________________________ > BioSQL-l mailing list > BioSQL-l@open-bio.org http://open-bio.org/mailman/listinfo/biosql-l > From christen at unice.fr Mon Dec 8 08:57:32 2003 From: christen at unice.fr (christen) Date: Mon Dec 8 09:02:08 2003 Subject: [BioSQL-l] python Message-ID: <012101c3bd93$39ee0c10$2b113b86@christen2002> Hi there I am a new comer to python and biosql I have tried to get working biosql under mysql and python as ewplained in Basic BioSQL with Biopoython I have donwloaded the latest version of both, and tried the example with cor6_6.gb then I got numerous problems I fixed the first one by changing line 104 in cursors from if args is None: to : if args is None or args=='': then in Loader, in def _load_reference(self, reference, rank, bioentry_id):, i made the following changes (in particular replaced JOIN by INNER JOIN) if reference.medline_id: sql="SELECT reference_id" \ " FROM reference INNER JOIN dbxref ON reference .dbxref_id = dbxref.dbxref_id" \ " WHERE ((dbname = 'MEDLINE') AND (accession = %s))" refs = self.adaptor.execute_and_fetch_col0(sql,reference.medline_id) Now, I have one more pb: Traceback (most recent call last): File "C:\Python23\RC_databases\rc_BioSQL_GenBank.py", line 21, in -toplevel- db.load(iterator) File "C:\Python23\lib\site-packages\BioSQL\BioSeqDatabase.py", line 343, in load db_loader.load_seqrecord(cur_record) File "C:\Python23\lib\site-packages\BioSQL\Loader.py", line 46, in load_seqrecord self._load_seqfeature(seq_feature, seq_feature_num, bioentry_id) File "C:\Python23\lib\site-packages\BioSQL\Loader.py", line 366, in _load_seqfeature self._load_seqfeature_locations(feature, seqfeature_id) File "C:\Python23\lib\site-packages\BioSQL\Loader.py", line 409, in _load_seqfeature_locations self._insert_seqfeature_location(feature, 1, seqfeature_id) File "C:\Python23\lib\site-packages\BioSQL\Loader.py", line 430, in _insert_seqfeature_location self.adaptor.execute(sql, (seqfeature_id, start, end, strand, rank)) File "C:\Python23\lib\site-packages\BioSQL\BioSeqDatabase.py", line 223, in execute self.cursor.execute(sql, args) File "C:\Python23\lib\site-packages\MySQLdb\cursors.py", line 95, in execute return self._execute(query, args) File "C:\Python23\lib\site-packages\MySQLdb\cursors.py", line 119, in _execute self.errorhandler(self, exc, value) File "C:\Python23\Lib\site-packages\MySQLdb\connections.py", line 33, in defaulterrorhandler raise errorclass, errorvalue OperationalError: (1048, "Le champ 'strand' ne peut \xeatre vide (null)") I am for the time being only trying some quick and dirty (like modification of cursor instead of loader I guess...) changes to try to get it working My questions are : Is there somebody else having trouble, or do you I miss something ? If I did it right, Is there somebody else trying to fix these problems ? If things need some help, it would be very nice to have some clear description of biosql structure. I have not been able to find it. Somebody could help ? thanks in advance Richard CHRISTEN Champion de saut en largeur UMR6543 CNRS - Universit? de Nice Sophia Antipolis Centre de Biochimie Parc Valrose 06108 Nice cedex2 tel 33 - 492 076 947 fax 33 - 492 076 408 From Yves.Bastide at irisa.fr Mon Dec 8 09:47:53 2003 From: Yves.Bastide at irisa.fr (Yves Bastide) Date: Mon Dec 8 09:54:02 2003 Subject: [BioSQL-l] python In-Reply-To: <012101c3bd93$39ee0c10$2b113b86@christen2002> References: <012101c3bd93$39ee0c10$2b113b86@christen2002> Message-ID: <3FD48F19.6040403@irisa.fr> [kept bioSQL cc'ed, f'up to biopython-dev@biopython.org] christen wrote: > Hi there > > I am a new comer to python and biosql > > I have tried to get working biosql under mysql and python as ewplained in > Basic BioSQL with Biopoython OK, mysql vs. postgresql issues. > I have donwloaded the latest version of both, and tried the example with > cor6_6.gb > > then I got numerous problems > > I fixed the first one by changing line 104 in cursors from > if args is None: > to : > if args is None or args=='': > Where's this line? "args is None" looks like something done to allow the empty string; the usual way (to mean what you're using) would be "if not args:" > then in Loader, in def _load_reference(self, reference, rank, bioentry_id):, > i made the following changes (in particular replaced JOIN by INNER JOIN) > if reference.medline_id: > sql="SELECT reference_id" \ > " FROM reference INNER JOIN dbxref ON reference .dbxref_id > = dbxref.dbxref_id" \ > " WHERE ((dbname = 'MEDLINE') AND (accession = %s))" > refs = > self.adaptor.execute_and_fetch_col0(sql,reference.medline_id) > JOIN -> INNER JOIN: ok using (field) -> on t1.field = t2.field: *sigh* ok But are the extraneous parentheses really needed? > > Now, I have one more pb: > > Traceback (most recent call last): > File "C:\Python23\RC_databases\rc_BioSQL_GenBank.py", line 21, > in -toplevel- > db.load(iterator) > File "C:\Python23\lib\site-packages\BioSQL\BioSeqDatabase.py", line 343, > in load > db_loader.load_seqrecord(cur_record) > File "C:\Python23\lib\site-packages\BioSQL\Loader.py", line 46, in > load_seqrecord > self._load_seqfeature(seq_feature, seq_feature_num, bioentry_id) > File "C:\Python23\lib\site-packages\BioSQL\Loader.py", line 366, in > _load_seqfeature > self._load_seqfeature_locations(feature, seqfeature_id) > File "C:\Python23\lib\site-packages\BioSQL\Loader.py", line 409, in > _load_seqfeature_locations > self._insert_seqfeature_location(feature, 1, seqfeature_id) > File "C:\Python23\lib\site-packages\BioSQL\Loader.py", line 430, in > _insert_seqfeature_location > self.adaptor.execute(sql, (seqfeature_id, start, end, strand, rank)) > File "C:\Python23\lib\site-packages\BioSQL\BioSeqDatabase.py", line 223, > in execute > self.cursor.execute(sql, args) > File "C:\Python23\lib\site-packages\MySQLdb\cursors.py", line 95, in > execute > return self._execute(query, args) > File "C:\Python23\lib\site-packages\MySQLdb\cursors.py", line 119, in > _execute > self.errorhandler(self, exc, value) > File "C:\Python23\Lib\site-packages\MySQLdb\connections.py", line 33, in > defaulterrorhandler > raise errorclass, errorvalue > OperationalError: (1048, "Le champ 'strand' ne peut \xeatre vide (null)") Hilmar: seems like there's a buglet in biosqldb-pg.sql: strand is missing the NOT NULL. Richard: Loader.py, line 424 - strand = feature.strand + strand = feature.strand or 0 should do the trick > > > I am for the time being only trying some quick and dirty (like modification > of cursor instead of loader I guess...) changes to try to get it working > My questions are : > Is there somebody else having trouble, or do you I miss something ? > If I did it right, Is there somebody else trying to fix these problems ? It seems like you're the first trying these things with MySQL since they were last changed. Thanks for the report! > If things need some help, it would be very nice to have some clear > description of biosql structure. I have not been able to find it. Somebody > could help ? > > thanks in advance De rien, > > Richard CHRISTEN > Champion de saut en largeur > UMR6543 CNRS - Universit? de Nice Sophia Antipolis > > Centre de Biochimie > Parc Valrose > 06108 Nice cedex2 > > tel 33 - 492 076 947 > fax 33 - 492 076 408 > yves From jvhan at pandora.be Tue Dec 9 15:32:26 2003 From: jvhan at pandora.be (jack van handenhove) Date: Tue Dec 9 22:16:06 2003 Subject: [BioSQL-l] biosql on sybase? Message-ID: <003001c3be93$91bdc970$18dca451@acshome> Dear All, I am currently investigating the use of bioperl and underlying biosql database to build a repository of genetic data. as the inhouse database system is sybase, the biosql-db modules should be adapted for use with this system. could you give an estimation of the amount of work that would be involved in porting these modules to sybase? And what exactly should be done. Which scripts should be adapted? is there only Perl scripts involved or also C? besides that, the schema should also be migrated, although I do not see a lot of difficulties there. As the schema is stable, it seems like choosing the correct datatypes that correspond to those used in the existing schema. Unless the Oracle schema, which would serve as the model, implements a lot of triggers an stored procedures? Please know that I am a programmer with moderate perl experience. Are there other modules besides bioperl-db, that should be ported? thanks for your reply, Jack From raphael.bauer at informatik.hu-berlin.de Mon Dec 15 10:00:19 2003 From: raphael.bauer at informatik.hu-berlin.de (Raphael A. Bauer) Date: Mon Dec 15 10:06:11 2003 Subject: [BioSQL-l] One Datasource => One Comment? Message-ID: <3FDDCC83.9090809@informatik.hu-berlin.de> Hello BioSQL List, When I parse Swissprot or Genbank or EMBL into a newly generated biosql schema - is it possible that there can be generated more than one comment entries for a single bioentry? I would think that more comments for a single bioentry can only happen if there is more than one datasource in the biosql-schema (eg. Genbank and Swissprot together). Am I right? Thank you very much, Raphael Bauer From Marc.Logghe at devgen.com Mon Dec 15 10:19:12 2003 From: Marc.Logghe at devgen.com (Marc Logghe) Date: Mon Dec 15 10:25:20 2003 Subject: [BioSQL-l] One Datasource => One Comment? Message-ID: > -----Original Message----- > From: Raphael A. Bauer [mailto:raphael.bauer@informatik.hu-berlin.de] > Sent: Monday, December 15, 2003 4:00 PM > To: biosql-l@open-bio.org > Subject: [BioSQL-l] One Datasource => One Comment? > > > Hello BioSQL List, > > When I parse Swissprot or Genbank or EMBL into a newly > generated biosql > schema - is it possible that there can be generated more than one > comment entries for a single bioentry? Sure, that is possible. They even get an internal ranking so that when you fetch the bioentry from biosql and dump it as say, genbank, they end up in the same order as originally entered. > I would think that more comments for a single bioentry can > only happen > if there is more than one datasource in the biosql-schema > (eg. Genbank > and Swissprot together). > Am I right? I don't follow you here. Every COMMENT field from the original genbank record becomes a separate entry in the comment table, which is linked to the bioentry via its FK (Bioentry ID) HTH, Marc From hlapp at gnf.org Mon Dec 15 12:11:12 2003 From: hlapp at gnf.org (Hilmar Lapp) Date: Mon Dec 15 12:17:14 2003 Subject: [BioSQL-l] One Datasource => One Comment? In-Reply-To: <3FDDCC83.9090809@informatik.hu-berlin.de> Message-ID: On Monday, December 15, 2003, at 07:00 AM, Raphael A. Bauer wrote: > Hello BioSQL List, > > When I parse Swissprot or Genbank or EMBL into a newly generated > biosql schema - is it possible that there can be generated more than > one comment entries for a single bioentry? If the original entry had more than one comment then yes. Swissprot should have always only one comment I'd claim, but I really don't know for sure. > I would think that more comments for a single bioentry can only happen > if there is more than one datasource in the biosql-schema (eg. Genbank > and Swissprot together). > This is hardly possible. Theoretically it can happen if you assigned the same namespace to both datasources and chose to update records when loading the second datasource, but then the records needed to have the same accession numbers, which GenBank and Swissprot really don't. Otherwise, if you assigned different namespaces the bioentries will be different. -hilmar > Am I right? > > Thank you very much, > > Raphael Bauer > > _______________________________________________ > BioSQL-l mailing list > BioSQL-l@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 ------------------------------------------------------------- From jjliu at cs.nchu.edu.tw Wed Dec 17 10:15:24 2003 From: jjliu at cs.nchu.edu.tw (Jim Liu) Date: Wed Dec 17 10:23:36 2003 Subject: [BioSQL-l] Can I just consider import HGI.101403 to biosequence table? References: Message-ID: <003101c3c4b0$99616150$ee213e3d@jimhome> Dear All, I went to ftp://ftp.tigr.org/pub/data/tgi/Homo_sapiens/ and downloaded HGI.release_13.zip. There are 4 data files: 479,047,691 HGI.101403 57,653,798 HGI.TC_EST.101403 12,629,591 HGI.TCs.101403 10,303,001 HGI.GO.101403 I would like to import to MySQL database. I already applied BioSQL schema on MySQL. Can I just consider import HGI.101403 to biosequence table? How about the other data files? How to find the detail definition of these data files? Thanks. Jim Liu From hlapp at gnf.org Wed Dec 17 11:23:26 2003 From: hlapp at gnf.org (Hilmar Lapp) Date: Wed Dec 17 11:29:18 2003 Subject: [BioSQL-l] Can I just consider import HGI.101403 to biosequence table? In-Reply-To: <003101c3c4b0$99616150$ee213e3d@jimhome> Message-ID: <57BCBD9E-30AD-11D8-BADE-000A959EB4C4@gnf.org> On Wednesday, December 17, 2003, at 07:15 AM, Jim Liu wrote: > Dear All, > > I went to ftp://ftp.tigr.org/pub/data/tgi/Homo_sapiens/ > and downloaded HGI.release_13.zip. > There are 4 data files: > > 479,047,691 HGI.101403 > 57,653,798 HGI.TC_EST.101403 > 12,629,591 HGI.TCs.101403 > 10,303,001 HGI.GO.101403 > > I would like to import to MySQL database. > I already applied BioSQL schema on MySQL. > Can I just consider import HGI.101403 to biosequence table? You'd also want to populate other tables. Generally I'd think you should be able to import those data into biosql; whether or not you can use the supplied tools to do it basically depends on whether there is a bioperl SeqIO parser for the format. So, check whether the SeqIO/tigr.pm XML parser is the one you need here; otherwise you could still write your own. -hilmar > How about the other data files? > How to find the detail definition of these data files? > > Thanks. > > Jim Liu > > _______________________________________________ > BioSQL-l mailing list > BioSQL-l@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 ------------------------------------------------------------- From laurichj at bioinfo.ucr.edu Wed Dec 17 12:26:35 2003 From: laurichj at bioinfo.ucr.edu (Josh Lauricha) Date: Wed Dec 17 12:32:25 2003 Subject: [BioSQL-l] Can I just consider import HGI.101403 to biosequence table? In-Reply-To: <57BCBD9E-30AD-11D8-BADE-000A959EB4C4@gnf.org> References: <003101c3c4b0$99616150$ee213e3d@jimhome> <57BCBD9E-30AD-11D8-BADE-000A959EB4C4@gnf.org> Message-ID: <20031217172635.GA16189@bioinfo.ucr.edu> On Wed 12/17/03 08:23, Hilmar Lapp wrote: > > On Wednesday, December 17, 2003, at 07:15 AM, Jim Liu wrote: > > >Dear All, > > > >I went to ftp://ftp.tigr.org/pub/data/tgi/Homo_sapiens/ > >and downloaded HGI.release_13.zip. > >There are 4 data files: > > > >479,047,691 HGI.101403 > > 57,653,798 HGI.TC_EST.101403 > > 12,629,591 HGI.TCs.101403 > > 10,303,001 HGI.GO.101403 > > > >I would like to import to MySQL database. > >I already applied BioSQL schema on MySQL. > >Can I just consider import HGI.101403 to biosequence table? > > You'd also want to populate other tables. Generally I'd think you > should be able to import those data into biosql; whether or not you can > use the supplied tools to do it basically depends on whether there is a > bioperl SeqIO parser for the format. So, check whether the > SeqIO/tigr.pm XML parser is the one you need here; otherwise you could > still write your own. > Wanting to test SeqIO/tigr.pm on more files I took a look at them... These files are in various formats, some appear to be search results. Those can't be imported into BioSQL, as far as I know. The only file that could be is HGI.101403, which is in Fasta. So the best bet for this is just to use an index such as Bio::Index::Fasta, unless you want to do searching on the descriptions. Even then, it wouldn't be to hard to write a quick and dirty DB_File index for those. On a side note, is there anything thats more efficient at getting a sequence from BioSQL than Bio::DB::BioDB? All the transformations done by that interface make it too slow to use on a webpage. > >How about the other data files? > >How to find the detail definition of these data files? > > > >Thanks. > > > >Jim Liu > > > >_______________________________________________ > >BioSQL-l mailing list > >BioSQL-l@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 > ------------------------------------------------------------- > > > _______________________________________________ > BioSQL-l mailing list > BioSQL-l@open-bio.org > http://open-bio.org/mailman/listinfo/biosql-l > -- ---------------------------- | Josh Lauricha | | laurichj@bioinfo.ucr.edu | | Bioinformatics, UCR | |--------------------------| From hlapp at gnf.org Wed Dec 17 13:01:21 2003 From: hlapp at gnf.org (Hilmar Lapp) Date: Wed Dec 17 13:07:13 2003 Subject: [BioSQL-l] Can I just consider import HGI.101403 to biosequence table? In-Reply-To: <20031217172635.GA16189@bioinfo.ucr.edu> Message-ID: <0560C257-30BB-11D8-9AA1-000A959EB4C4@gnf.org> On Wednesday, December 17, 2003, at 09:26 AM, Josh Lauricha wrote: > On a side note, is there anything thats more efficient at getting a > sequence from BioSQL than Bio::DB::BioDB? All the transformations done > by that interface make it too slow to use on a webpage. > Not for perl AFAIK. What is the response time that you're looking for? What is the search that you execute? A single sequence record located by unique key should return in a fraction of a second that's shorter than the browser page build-up combined with the network latency, provided you back it with a decent database server. Note that the bioperl-db code makes extensive use of caching. If you fire up a CGI each and every time you hit the page, you won't take any advantage of that. -hilmar -- ------------------------------------------------------------- Hilmar Lapp email: lapp at gnf.org GNF, San Diego, Ca. 92121 phone: +1-858-812-1757 ------------------------------------------------------------- From hlapp at gnf.org Wed Dec 17 14:07:56 2003 From: hlapp at gnf.org (Hilmar Lapp) Date: Wed Dec 17 14:13:47 2003 Subject: [BioSQL-l] Can I just consider import HGI.101403 to biosequence table? In-Reply-To: <20031217185059.GD16189@bioinfo.ucr.edu> Message-ID: <52C4B319-30C4-11D8-9AA1-000A959EB4C4@gnf.org> On Wednesday, December 17, 2003, at 10:50 AM, Josh Lauricha wrote: > The select took basically no time, but the time spent inside Bio::* was > significant. This is on quad xeon 1.9GHz with 8GB RAM... so it was > probably something with the local setup, or I'm confusing things. > Hm. Try to execute the search with a unique key query ($adp->find_by_unique_key()). There should be no difference. If there is then it hints at a bioperl-db problem, or at a missing or wrong index on accession number. But you say the select was fast. Note that by the time you get the record returned as an object, several tens of selects will have been executed to fetch all the related entities. The only time this would take several seconds is if your accession is for a unigene cluster with hundreds or even thousands of members, because each member is a bioentry itself. Note that you can turn on a lot (!) of debugging output by setting $db->verbose(1) before you obtain any adaptor or persistent object from it. If you then watch the log online, you may see if there's any problem query where it stalls briefly. Some people have reported that the species retrieval in I believe mysql was a serious bottleneck (and then it is the sql query itself). Species are cached once they've been retrieved once, but if you restart the script every time you won't take advantage of this. -hilmar -- ------------------------------------------------------------- Hilmar Lapp email: lapp at gnf.org GNF, San Diego, Ca. 92121 phone: +1-858-812-1757 ------------------------------------------------------------- From Frederic.Pecqueur at devgen.com Mon Dec 22 10:05:17 2003 From: Frederic.Pecqueur at devgen.com (Frederic Pecqueur) Date: Mon Dec 22 10:12:57 2003 Subject: [BioSQL-l] Query Problem. Message-ID: Hi, I try to create a query to search all the entries which have a tag "other_name" equal to 'mig-11'....and it dosen't work... I use this code : my $adp = $db->get_object_adaptor('Bio::PrimarySeqI'); my $query = Bio::DB::Query::BioQuery->new( -datacollections => [ "Bio::PrimarySeqI entr", "Bio::SeqFeatureI feat", "Bio::Ontology::TermI ter", "BioNamespace=>Bio::PrimarySeqI db", "Bio::PrimarySeqI=>Bio::SeqFeatureI", "Bio::SeqFeatureI<=>Bio::Ontology::TermI qual" ], -where => ["db.namespace = 'WormGene'", "ter.name = 'other_name'", "qual.value = 'mig-11'"] ); my $result = $adp->find_by_query($query); I have this error : attempting to load driver for adaptor class Bio::DB::BioSQL::PrimarySeqAdaptor attempting to load driver for adaptor class Bio::DB::BioSQL::BasePersistenceAdaptor Using Bio::DB::BioSQL::Oracle::BasePersistenceAdaptorDriver as driver peer for Bio::DB::BioSQL::PrimarySeqAdaptor ------------- EXCEPTION ------------- MSG: Alias "q" not mapped to entity. Are you sure there's no typo? STACK Bio::DB::Query::BioQuery::_map_slot_to_col /usr/lib/perl5/site_perl/5.6.1/Bio/DB/Query/BioQuery.pm:466 STACK Bio::DB::Query::BioQuery::_map_constraint_slots_to_columns /usr/lib/perl5/site_perl/5.6.1/Bio/DB/Query/BioQuery.pm:369 STACK Bio::DB::Query::BioQuery::_map_constraint_slots_to_columns /usr/lib/perl5/site_perl/5.6.1/Bio/DB/Query/BioQuery.pm:355 STACK Bio::DB::Query::BioQuery::translate_query /usr/lib/perl5/site_perl/5.6.1/Bio/DB/Query/BioQuery.pm:305 STACK Bio::DB::BioSQL::BaseDriver::translate_query /usr/lib/perl5/site_perl/5.6.1/Bio/DB/BioSQL/BaseDriver.pm:1184 STACK Bio::DB::BioSQL::BasePersistenceAdaptor::find_by_query /usr/lib/perl5/site_perl/5.6.1/Bio/DB/BioSQL/BasePersistenceAdaptor.pm:1198 I don't use the API correctly?? Somebody has a response? Thanks a lot! Fr?d?ric. From hlapp at gnf.org Mon Dec 22 11:26:32 2003 From: hlapp at gnf.org (Hilmar Lapp) Date: Mon Dec 22 11:34:11 2003 Subject: [BioSQL-l] Query Problem. In-Reply-To: Message-ID: <9A94C2C2-349B-11D8-AE25-000A959EB4C4@gnf.org> This error is pretty weird. Smells like a bug, I'm just not sure where. Try collapsing the multiple spaces between entity and alias into a single space for every datacollection and see whether it goes away. I can't tell where it would get the 'q' as an alias from. A tip aside from that: I'd request the adaptor for Bio::SeqI or otherwise you won't get features and annotation on the resulting objects. -hilmar On Monday, December 22, 2003, at 07:05 AM, Frederic Pecqueur wrote: > Hi, > > I try to create a query to search all the entries which have a tag > "other_name" equal to 'mig-11'....and it dosen't work... > > I use this code : > > my $adp = $db->get_object_adaptor('Bio::PrimarySeqI'); > > my $query = Bio::DB::Query::BioQuery->new( > -datacollections => [ > "Bio::PrimarySeqI entr", > "Bio::SeqFeatureI feat", > "Bio::Ontology::TermI ter", > "BioNamespace=>Bio::PrimarySeqI db", > "Bio::PrimarySeqI=>Bio::SeqFeatureI", > "Bio::SeqFeatureI<=>Bio::Ontology::TermI qual" > ], > -where => ["db.namespace = 'WormGene'", > "ter.name = 'other_name'", > "qual.value = 'mig-11'"] > ); > > my $result = $adp->find_by_query($query); > > I have this error : > > attempting to load driver for adaptor class > Bio::DB::BioSQL::PrimarySeqAdaptor > attempting to load driver for adaptor class > Bio::DB::BioSQL::BasePersistenceAdaptor > Using Bio::DB::BioSQL::Oracle::BasePersistenceAdaptorDriver as driver > peer for Bio::DB::BioSQL::PrimarySeqAdaptor > > ------------- EXCEPTION ------------- > MSG: Alias "q" not mapped to entity. Are you sure there's no typo? > STACK Bio::DB::Query::BioQuery::_map_slot_to_col > /usr/lib/perl5/site_perl/5.6.1/Bio/DB/Query/BioQuery.pm:466 > STACK Bio::DB::Query::BioQuery::_map_constraint_slots_to_columns > /usr/lib/perl5/site_perl/5.6.1/Bio/DB/Query/BioQuery.pm:369 > STACK Bio::DB::Query::BioQuery::_map_constraint_slots_to_columns > /usr/lib/perl5/site_perl/5.6.1/Bio/DB/Query/BioQuery.pm:355 > STACK Bio::DB::Query::BioQuery::translate_query > /usr/lib/perl5/site_perl/5.6.1/Bio/DB/Query/BioQuery.pm:305 > STACK Bio::DB::BioSQL::BaseDriver::translate_query > /usr/lib/perl5/site_perl/5.6.1/Bio/DB/BioSQL/BaseDriver.pm:1184 > STACK Bio::DB::BioSQL::BasePersistenceAdaptor::find_by_query > /usr/lib/perl5/site_perl/5.6.1/Bio/DB/BioSQL/ > BasePersistenceAdaptor.pm:1198 > > I don't use the API correctly?? > Somebody has a response? > > Thanks a lot! > Fr?d?ric. > > _______________________________________________ > BioSQL-l mailing list > BioSQL-l@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 ------------------------------------------------------------- From laurichj at bioinfo.ucr.edu Tue Dec 23 19:34:17 2003 From: laurichj at bioinfo.ucr.edu (Josh Lauricha) Date: Tue Dec 23 19:41:44 2003 Subject: [BioSQL-l] Can I just consider import HGI.101403 to biosequence table? In-Reply-To: <52C4B319-30C4-11D8-9AA1-000A959EB4C4@gnf.org> References: <20031217185059.GD16189@bioinfo.ucr.edu> <52C4B319-30C4-11D8-9AA1-000A959EB4C4@gnf.org> Message-ID: <20031224003417.GB15277@bioinfo.ucr.edu> On Wed 12/17/03 11:07, Hilmar Lapp wrote: > Hm. Try to execute the search with a unique key query > ($adp->find_by_unique_key()). There should be no difference. If there > is then it hints at a bioperl-db problem, or at a missing or wrong > index on accession number. The code that I can still find from playing with this ran fine, so it must have been something I was doing. Unfortunatly, I don't have that code anymore. -- ---------------------------- | Josh Lauricha | | laurichj@bioinfo.ucr.edu | | Bioinformatics, UCR | |--------------------------| From Richard.Holland at agresearch.co.nz Mon Dec 29 22:07:51 2003 From: Richard.Holland at agresearch.co.nz (Holland, Richard) Date: Tue Dec 30 12:39:35 2003 Subject: [BioSQL-l] Cannot make test on bioperl-db Message-ID: Apologies for the cross-post but I am not sure if it is BioSQL or BioPerl at fault here. I have installed the Oracle version of BioSQL and bioperl-db as downloaded last week, and they compile and install fine. However, make test on bioperl-db fails miserably with hundreds of messages similar to the following on virtually every module: ---SNIP--- bifo6.agresearch.co.nz> make test PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/cluster.......ok 155/160DBD::Oracle::st execute failed: ORA-00001: unique constraint (SGOWNER.XPKBIOENTRY_QUALIFIER_ASSOC) violated (DBD ERROR: OCIStmtExecute) [for Statement "INSERT INTO bioentry_qualifier_value (ent_oid, trm_oid, value, rank) VALUES (?, ?, ?, ?)" with ParamValues: :p3='ORG=Escherischia coli; PROTGI=8928262; PROTID=Ec_pid; PCT=24; ALN=254', :p1='417', :p4=1, :p2='421'] at /usr/users/oracle/bioperl-db/blib/lib/Bio/DB/BioSQL/BasePersistenceAdapt or.pm line 418, line 1. DBD::Oracle::st execute failed: ORA-00001: unique constraint (SGOWNER.XPKBIOENTRY_QUALIFIER_ASSOC) violated (DBD ERROR: OCIStmtExecute) [for Statement "INSERT INTO bioentry_qualifier_value (ent_oid, trm_oid, value, rank) VALUES (?, ?, ?, ?)" with ParamValues: :p3='ORG=Homo sapiens; PROTGI=114238; PROTID=sp:P11245; PCT=100; ALN=289', :p1='417', :p4=2, :p2='421'] at /usr/users/oracle/bioperl-db/blib/lib/Bio/DB/BioSQL/BasePersistenceAdapt or.pm line 418, line 1. DBD::Oracle::st execute failed: ORA-00001: unique constraint (SGOWNER.XPKBIOENTRY_QUALIFIER_ASSOC) violated (DBD ERROR: OCIStmtExecute) [for Statement "INSERT INTO bioentry_qualifier_value (ent_oid, trm_oid, value, rank) VALUES (?, ?, ?, ?)" with ParamValues: :p3='ORG=Mus musculus; PROTGI=1703436; PROTID=sp:P50295; PCT=74; ALN=289', :p1='417', :p4=3, :p2='421'] at /usr/users/oracle/bioperl-db/blib/lib/Bio/DB/BioSQL/BasePersistenceAdapt or.pm line 418, line 1. DBD::Oracle::st execute failed: ORA-00001: unique constraint (SGOWNER.XPKBIOENTRY_QUALIFIER_ASSOC) violated (DBD ERROR: OCIStmtExecute) [for Statement "INSERT INTO bioentry_qualifier_value (ent_oid, trm_oid, value, rank) VALUES (?, ?, ?, ?)" with ParamValues: :p3='ORG=Rattus norvegicus; PROTGI=1703437; PROTID=sp:P50298; PCT=73; ALN=289', :p1='417', :p4=4, :p2='421'] at /usr/users/oracle/bioperl-db/blib/lib/Bio/DB/BioSQL/BasePersistenceAdapt or.pm line 418, line 1. ---SNIP--- My installation includes the text indexer option, and I have run the script to load the taxon information (which incidentally took almost 20 hours to run on a three-processor Compaq Alpha with 11 gigs of RAM - that's also a bit of a worry, surely?). The only tables with any data in (I have checked this) are taxon and taxon_name. The test failed before I loaded the taxon information in exactly the same way as it does now. I am wary of wasting time trying to load real data if the test fails like this - is it a 'fatal' problem or can I ignore it and load real data anyway? Any idea what's going on here? I can't figure it out. cheers, Richard --- Richard Holland Bioinformatics Database Developer ITS, Agresearch Invermay x3279 ======================================================================= Attention: The information contained in this message and/or attachments from AgResearch Limited is intended only for the persons or entities to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipients is prohibited by AgResearch Limited. If you have received this message in error, please notify the sender immediately. =======================================================================