From: Nicolas J. <nic...@gm...> - 2012-04-12 04:45:06
|
Hello, I am proceeding with inserting data into my gusdb. I downloaded the latest so.obo file from www.sequenceontology.org and added that data to the db (see output below). Once that done, I tried to insert sequence features but ran into the following error message: ERROR: Can't find primary key for SO term 'gene' Going through the code to find the error, I've manually checked the output of the following sql code: select term_name, sequence_ontology_id from sres.SequenceOntology where so_cvs_version = '$soCvsVersion' In my case the soCvsVersion is 1.324. And the result was nothing. So I checked the table in question, and found it full of data, but with an erroneous soCvsVersion: the InsertSequenceOntologyOBO plugin seems to have used the soVersion as both the soVersion and the soCvsVersion. Is this a bug in that plugin or is it supposed to be that way? If it is a bug, I found in the InsertSequenceOntologyOBO.pm file the following code (lines 170 to 178): my $soTerm = GUS::Model::SRes::SequenceOntology-> new({'so_id' => $obo->{'id'}, 'ontology_name' => 'sequence', 'so_version' => $soVer, *'so_cvs_version' => $soVer,* 'term_name' => $obo->{'name'}, 'definition' => $definition }); return $soTerm; Is there a specific way to update the table (I don't see any UNDO for this plugin)? Or should I just use plain sql UPDATE for this? Best regards, Nicolas Nicolas-work-iMac:~ Nicolas$ ga GUS::Supported::Plugin::InsertSequenceOntologyOBO --inputFile ~/Data_for_GUS/so.obo --soVersion 1.2 --soCvsVersion 1.324 --commit Wed Apr 11 15:51:53 2012 DSN dbi:Pg:dbname=varDB_2012 Wed Apr 11 15:51:53 2012 PLUGIN GUS::Supported::Plugin::InsertSequenceOntologyOBO Wed Apr 11 15:51:53 2012 ARG algoinvo 1 Wed Apr 11 15:51:53 2012 ARG comment Wed Apr 11 15:51:53 2012 ARG commit 1 Wed Apr 11 15:51:53 2012 ARG debug 0 Wed Apr 11 15:51:53 2012 ARG group Wed Apr 11 15:51:53 2012 ARG gusconfigfile /Users/Nicolas/GUS/gus_home/config/gus.config Wed Apr 11 15:51:53 2012 ARG help 0 Wed Apr 11 15:51:53 2012 ARG helpHTML 0 Wed Apr 11 15:51:53 2012 ARG inputFile /Data_for_GUS/so.obo Wed Apr 11 15:51:53 2012 ARG project Wed Apr 11 15:51:53 2012 ARG soCvsVersion 1.324 Wed Apr 11 15:51:53 2012 ARG soExtDbRlsName Wed Apr 11 15:51:53 2012 ARG soVersion 1.2 Wed Apr 11 15:51:53 2012 ARG sqlVerbose 0 Wed Apr 11 15:51:53 2012 ARG user Wed Apr 11 15:51:53 2012 ARG verbose 0 Wed Apr 11 15:51:53 2012 ARG veryVerbose 0 Wed Apr 11 15:51:53 2012 ARG workflowstepid 0 Wed Apr 11 15:51:53 2012 AlgInvocationId 29 Wed Apr 11 15:51:53 2012 COMMIT commit on Wed Apr 11 15:51:54 2012 Submitted 100 terms Wed Apr 11 15:51:54 2012 Submitted 200 terms Wed Apr 11 15:51:54 2012 Submitted 300 terms Wed Apr 11 15:51:54 2012 Submitted 400 terms Wed Apr 11 15:51:54 2012 Submitted 500 terms Wed Apr 11 15:51:54 2012 Submitted 600 terms Wed Apr 11 15:51:54 2012 Submitted 700 terms Wed Apr 11 15:51:54 2012 Submitted 800 terms Wed Apr 11 15:51:54 2012 Submitted 900 terms Wed Apr 11 15:51:55 2012 Submitted 1000 terms Wed Apr 11 15:51:55 2012 Submitted 1100 terms Wed Apr 11 15:51:55 2012 Submitted 1200 terms Wed Apr 11 15:51:55 2012 Submitted 1300 terms Wed Apr 11 15:51:55 2012 Submitted 1400 terms Wed Apr 11 15:51:55 2012 Submitted 1500 terms Wed Apr 11 15:51:55 2012 Submitted 1600 terms Wed Apr 11 15:51:55 2012 Submitted 1700 terms Wed Apr 11 15:51:55 2012 Submitted 1800 terms Wed Apr 11 15:51:56 2012 Submitted 1900 terms Wed Apr 11 15:51:56 2012 Submitted 2000 terms Wed Apr 11 15:51:56 2012 Submitted 2100 terms Wed Apr 11 15:51:56 2012 TIME 3 sec (0:00:03) Wed Apr 11 15:51:56 2012 RESULT Inserted 2120 terms into SequenceOntology Wed Apr 11 15:51:56 2012 Rows Written SRes.SequenceOntology: 2120 Wed Apr 11 15:51:56 2012 AlgInvocationId 29 Wed Apr 11 15:51:56 2012 COMMIT commit on |