[Biojava-l] Biojavax and hibernate problems

Zagato zagato.gekko at gmail.com
Tue Apr 24 14:41:40 UTC 2007


Hello....

May be using RichStreamReader doesn't complete right the asocciate
information for the sequence, like references and annotations, i don't
know... why don't you try using org.biojavax.bio.seq.RichSequence.IOTools,
they implements a lots of good tools for reading sequences....

May be something like this:

String path = "/home/bertrand/IdeaProjects/ncRNAs/data/test.gbk";
BufferedReader br = new BufferedReader( new FileReader(path) );
RichSequenceIterator rsi =
org.biojavax.bio.seq.RichSequence.IOTools.readGenbankDNA( br, new
SimpleNamespace("sequence") );
// or readGenbankRNA if you have an ARN sequence: go to:
http://www.biojava.org/docs/api15b/org/biojavax/bio/seq/RichSequence.IOTools.html
while( rsi.hasNext() )
{
    RichSequence sequence = rsi.nextRichSequence();
    System.out.println( "Sequence identifier: "+sequence.getIdentifier() );
    try{
        tx.begin();
        session.saveOrUpdate( "Sequence", sequence );
        tx.commit();
    } catch(HibernateException ex){
        tx.rollback();
        ex.printStackTrace();
    }
}

i don't remember if this automaticaly saves the BioEntry for the Sequence, i
think yes, because the foreign key in the DB, in any case yo can retrive the
BioEntry genereted by IOTools from RichSequenceIterator using:
org.biojavax.bio.BioEntry bioentry = rsi.nextBioEntry();
// System.out.println( "Bioentry name: "+bioentry.getName() );

I hope this helps to you, and I'm recommend to you, read
http://www.biojava.org/wiki/BioJava:BioJavaXDocs ....

Bye...

Alan Jairo Acosta
Cali - Colombia

On 4/23/07, bertrand beckert <bertrand.beckert at gmail.com> wrote:
>
> Ok? I have tried what you said and it work for a simple exemple...
> Before I have tried to read my genbank file without using SessionFactory
> and it work well, it gave me the sequence and the anotation. But when I use
> SessionFactory and still using first RichStreamReader and then a
> RichSequence sequence as befotre it don't work anymore... I don't
> understand. Here is my code:
>
> public class LoadingData {
>
>      public static void addInDataBase() {
>        SessionFactory hibernateFactory = new
> Configuration().configure().buildSessionFactory();
>        Session session = hibernateFactory.openSession ();
>        RichObjectFactory.connectToBioSQL(session);
>        Transaction tx=session.beginTransaction();
>         try {
>             File f = new
> File("/home/bertrand/IdeaProjects/ncRNAs/data/test.gbk");
>             BufferedReader br = new BufferedReader(new FileReader(f));
>             RichSequenceFormat format = new GenbankFormat();
>             RichStreamReader seqsIn= new RichStreamReader(br,format,
> format.guessSymbolTokenization (f), RichSequenceBuilderFactory.FACTORY,new
> SimpleNamespace("sequence"));
>             RichSequence sequence = seqsIn.nextRichSequence();
>             tx.begin();
>             session.saveOrUpdate( "Sequence", sequence );
>             tx.commit();
>         } catch(HibernateException ex){
>              tx.rollback();
>             ex.printStackTrace();
>              System.out.println("Transaction error.");
>         }catch (IOException e) {
>         e.printStackTrace();
>         System.out.println("No file\n");
>         }catch (BioException e){
>         e.printStackTrace();
>         System.out.println("bioexeception\n");
>         } finally {
>            session.close();
>         }
>      }
>
>       public static void main(String[] args) {
>           addInDataBase();
>           }
>       }
>
> the error message:
>
> /usr/local/share/jdk1.5.0_03/bin/java - Didea.launcher.port=7533 -
> Didea.launcher.bin.path=/usr/local/share/idea-4192/bin -
> Dfile.encoding=UTF-8 -classpath
> /usr/local/share/jdk1.5.0_03/jre/lib/jce.jar:/usr/local/share/jdk1.5.0_03/jre/lib/javaws.jar:/usr/local/share/jdk1.5.0_03/jre/lib/jsse.jar:/usr/local/share/jdk1.5.0_03/jre/lib/deploy.jar:/usr/local/share/jdk1.5.0_03/jre/lib/charsets.jar:/usr/local/share/jdk1.5.0_03/jre/lib/plugin.jar:/usr/local/share/jdk1.5.0_03/jre/lib/rt.jar:/usr/local/share/jdk1.5.0_03/jre/lib/ext/sunjce_provider.jar:/usr/local/share/jdk1.5.0_03/jre/lib/ext/sunpkcs11.jar:/usr/local/share/jdk1.5.0_03/jre/lib/ext/dnsns.jar:/usr/local/share/jdk1.5.0_03/jre/lib/ext/localedata.jar:/home/bertrand/IdeaProjects/ncRNAs/build:/home/bertrand/IdeaProjects/ncRNAs/lib/mysql-
>
> connector-java-3.0.11-stable-bin.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/biojava-1.5-beta2.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/bytecode.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/commons-cli.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/hibernate3.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/log4j-1.2.11.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/asm.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/cglib-2.1.3.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/dom4j-1.6.1.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/jta.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/commons-logging-1.0.4.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/asm-attrs.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/ehcache-1.2.3.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/commons-collections-2.1.1.jar:/home/bertrand/IdeaProjects/ncRNAs/lib/antlr-2.7.5.jar:/usr/local/share/idea-4192/lib/idea_rt.jar
> com.intellij.rt.execution.application.AppMain
> fr.ustrasbg.ibmc.bbeckert.LoadingData
> 09:42:29,423  INFO Environment:509 - Hibernate 3.2.3
> 09:42:29,432  INFO Environment:542 - hibernate.properties not found
> 09:42:29,436  INFO Environment:676 - Bytecode provider name : cglib
> 09:42:29,449  INFO Environment:593 - using JDK 1.4 java.sql.Timestamphandling
> 09:42:29,656  INFO Configuration:1426 - configuring from resource:
> /hibernate.cfg.xml
> [...]
> 9:42:31,473  INFO SettingsFactory:250 - Optimize cache for minimal puts:
> disabled
> 09:42:31,474  INFO SettingsFactory:259 - Structured second-level cache
> entries: disabled
> 09:42:31,478  INFO SettingsFactory:286 - Statistics: disabled
> 09:42:31,478  INFO SettingsFactory:290 - Deleted entity synthetic
> identifier rollback: disabled
> 09:42:31,478  INFO SettingsFactory:305 - Default entity-mode: pojo
> 09:42:31,479  INFO SettingsFactory:309 - Named query checking : enabled
> 09:42:31,504  INFO SessionFactoryImpl:161 - building session factory
> 09:42:32,064  INFO SessionFactoryObjectFactory:82 - Not binding factory to
> JNDI, no JNDI name configured
> 09:42:32,467 DEBUG SQL:401 - select ontology0_.ontology_id as
> ontology1_3_, ontology0_.name as name3_, ontology0_.definition as
> definition3_ from ontology ontology0_ where ontology0_.name=?
> 09:42:32,550 DEBUG SQL:401 - insert into ontology (name, definition)
> values (?, ?)
> 09:42:32,682 DEBUG SQL:401 - insert into term (name, identifier,
> definition, is_obsolete, ontology_id) values (?, ?, ?, ?, ?)
> 09:42:32,686 DEBUG SQL:401 - insert into term (name, identifier,
> definition, is_obsolete, ontology_id) values (?, ?, ?, ?, ?)
> 09:42:32,751 DEBUG SQL:401 - insert into term (name, identifier,
> definition, is_obsolete, ontology_id) values (?, ?, ?, ?, ?)
> 09:42:32,755 DEBUG SQL:401 - insert into term (name, identifier,
> definition, is_obsolete, ontology_id) values (?, ?, ?, ?, ?)
> 09:42:32,758 DEBUG SQL:401 - insert into term (name, identifier,
> definition, is_obsolete, ontology_id) values (?, ?, ?, ?, ?)
> 09:42:32,768 DEBUG SQL:401 - select crossref0_.dbxref_id as dbxref1_16_,
> crossref0_.dbname as dbname16_, crossref0_.accession as accession16_,
> crossref0_.version as version16_ from dbxref crossref0_ where
> crossref0_.dbname=? and crossref0_.accession=? and crossref0_.version=?
> 09:42:32,771 DEBUG SQL:401 - insert into dbxref (dbname, accession,
> version) values (?, ?, ?)
> 09:42:32,785 DEBUG SQL:401 - select docref0_.reference_id as
> reference1_18_, docref0_.title as title18_, docref0_.authors as authors18_,
> docref0_.location as location18_, docref0_.crc as crc18_, docref0_.dbxref_id
> as dbxref6_18_ from reference docref0_ where docref0_.authors=? and
> docref0_.location=? and docref0_.title=?
> org.biojava.bio.BioException: Could not read sequence
>     at org.biojavax.bio.seq.io.RichStreamReader.nextRichSequence(
> RichStreamReader.java:113)
>     at fr.ustrasbg.ibmc.bbeckert.LoadingData.addInDataBase(
> LoadingData.java :41)
>     at fr.ustrasbg.ibmc.bbeckert.LoadingData.main(LoadingData.java:61)
>     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>     at sun.reflect.NativeMethodAccessorImpl.invoke(
> NativeMethodAccessorImpl.java :39)
>     at sun.reflect.DelegatingMethodAccessorImpl.invoke(
> DelegatingMethodAccessorImpl.java:25)
>     at java.lang.reflect.Method.invoke(Method.java:585)
>     at com.intellij.rt.execution.application.AppMain.main( AppMain.java
> :90)
> Caused by: java.lang.RuntimeException: Error while trying to call new
> class org.biojavax.SimpleDocRef(class java.lang.String,class
> java.lang.String,class java.lang.String)
>     at org.biojavax.bio.db.biosql.BioSQLRichObjectBuilder.buildObject (
> BioSQLRichObjectBuilder.java:166)
>     at org.biojavax.RichObjectFactory.getObject(RichObjectFactory.java
> :105)
>     at org.biojavax.bio.seq.io.GenbankFormat.readRichSequence(
> GenbankFormat.java:396)
>     at org.biojavax.bio.seq.io.RichStreamReader.nextRichSequence (
> RichStreamReader.java:110)
>     ... 7 more
> Caused by: java.lang.NoSuchMethodException: org.biojavax.SimpleDocRef
> .<init>(java.lang.String, java.lang.String, java.lang.String)
> bioexeception
>     at java.lang.Class.getConstructor0 (Class.java:2647)
>
>     at java.lang.Class.getConstructor(Class.java:1629)
>     at org.biojavax.bio.db.biosql.BioSQLRichObjectBuilder.buildObject(
> BioSQLRichObjectBuilder.java:147)
>     ... 10 more
>
> Process finished with exit code 0
>
>
> 2007/4/20, Zagato <zagato.gekko at gmail.com>:
> >
> > Hello.... i wonder if a more simple procedure works or not....
> >
> > Try don't using a RichSequenceDB, commenting:
> >            // RichSequenceDB db = new BioSQLRichSequenceDB(session);
> >
> > And try using...
> >
> >             t = session.beginTransaction();
> >             session.saveOrUpdate( "Sequence", gbkSeq );
> >             t.commit();
> >
> > This is without using a RichSequenceDB object, but using a RichSequence
> > directly....
> >
> > I used this for load a set of sequences in my postgres BioSQL database
> > and works for me.... Bye :D !!!!
> >
> > Alan Jairo Acosta
> > Cali - Colombia
> >
> > On 4/20/07, bertrand beckert <bertrand.beckert at gmail.com> wrote:
> >
> > >  Dear all,
> > >
> > > I am newbie  to java and biojavax... I have installed the BioSQL
> > > database
> > > and I have tried to connect to this base an put some data... In oder
> > > to do
> > > this I have installed Biojavax, and also hibernate (and the different
> > > .jar
> > > required). So I have tried to put some data but it didn't work... here
> > > is my
> > > code and the error in the output.
> > >
> > > Could you help me please. Thanks
> > >
> > > ---------
> > >
> > > package fr.ustrasbg.ibmc.bbeckert;
> > >
> > > import org.biojavax.bio.seq.io.RichSequenceBuilderFactory;
> > > import org.biojavax.bio.seq.io.RichSequenceFormat;
> > > import org.biojavax.bio.seq.io.RichStreamReader;
> > > import org.biojavax.bio.seq.io.GenbankFormat;
> > > import org.biojavax.bio.seq.RichSequence;
> > > import org.biojavax.bio.seq.RichFeature;
> > > import org.biojavax.bio.db.RichSequenceDB;
> > > import org.biojavax.bio.db.biosql.BioSQLRichSequenceDB;
> > > import org.biojavax.RichObjectFactory ;
> > > import org.biojava.bio.BioException;
> > > import org.biojava.bio.seq.db.IllegalIDException;
> > > import org.hibernate.Session;
> > > import org.hibernate.SessionFactory;
> > > import org.hibernate.Transaction;
> > > import org.hibernate.HibernateException ;
> > > import org.hibernate.cfg.Configuration;
> > >
> > > import java.io.File;
> > > import java.io.BufferedReader;
> > > import java.io.FileReader;
> > > import java.io.IOException;
> > > import java.util.Iterator;
> > >
> > > public class HibernatLoadingData {
> > >
> > >     public RichSequence gbkRichSeq (File f) {
> > >         [....]
> > >        return sequence;
> > >     }
> > >
> > > public static void loadingData (RichSequence gbkSeq){
> > >
> > >         SessionFactory sessionFactory = new
> > > Configuration().configure().buildSessionFactory();
> > >         Session session = sessionFactory.openSession();
> > >         RichObjectFactory.connectToBioSQL(session);
> > >         RichSequenceDB db = new BioSQLRichSequenceDB(session);
> > >
> > >         Transaction t=null;
> > >         try{
> > >             t = session.beginTransaction();
> > >             //test to kown is the database is active->true
> > >             System.out.println(t.isActive());
> > >              db.addRichSequence(gbkSeq);            //it should
> > > work...
> > >             t.commit();
> > >         } catch (HibernateException e) {
> > >             e.printStackTrace();
> > >             if (t != null && t.isActive())
> > >                 t.rollback();
> > >         } catch (BioException e) {
> > >                 e.printStackTrace();
> > >             }
> > >             session.close();
> > >         }
> > >
> > > public static void main(String[] args) {
> > >
> > >         File f = new
> > > File("/home/bertrand/IdeaProjects/ncRNAs/data/test.gbk");
> > >         HibernatLoadingData hl= new HibernatLoadingData();
> > >         RichSequence sequence=hl.gbkRichSeq(f);
> > >         loadingData(sequence);
> > >   }
> > > }
> > >
> > >
> > > output:
> > >              RichSequence gbkRichSeq:
> > >
> > > sequence name:CAK20891 AC:CAK20891
> > > Division:BCT
> > > length:688
> > > Protein start:1 end:688 Strand:POSITIVE
> > > MSKDFLLEIGLEEMPAQYVTSSVAQLEKRVSDWLNENQITFEKIKTYSTPRRLTVLVEAM
> > > AEEQANRVEEAKGPAKKIALDDEGNWSKAALGFARSQKVEPADLTFREIKGVEYIYIKKE
> > > VIGEKTTALLPSLEKVVTSMTFPVSMHWGSNDLRYIRPIKWLIAMFGEEIIPFEITGVST
> > > SNTSRGHRFLGKTATIKQPSDYPNALLEQFVVVNAEERKQAIVEQLRELESMENWQIKED
> > > EDLLEEVTNLVEYPTVLAGNFEKEYLELPEEVLITTMKEHQRYFPVFSKDEELLPHFVTV
> > > RNGNHENLDTVARGNEKVLRARLSDADFFYQEDLKITIDEAVAKLQNIVFHEKLGTLTEK
> > > MKRVQKVALMLADYLDWQEEDKQDIIRLTNIYKFDLVTNIVGEFPELQGLMGEKYALLQG
> > > EKPAIAIAIREHYLPSSAEGALPQTDLGSIIAIADKLETLVGFFCVNIVPTGSADPFGLR
> > > RSAFGAMRIIQANGWDIPVLELLSRIVDMERAEGAVELPSDDVKKEVQTFLKNRLRVVLQ
> > > NHHIRHDIIDAVIGGDPNTIPQLVDRAQILNKHVESDWFRPTVEALTRVMNISKKHEGNV
> > > EVDPSLFENKYEQALFDEIEKLKYDYANLTIVDRLRAFAALRTTIDDYFDNTLVMSENIE
> > > LKNNRLALLFELASFIKEFAQMDEINVK
> > > (log4j.properties)
> > > 10:14:06,582  INFO Environment:509 - Hibernate 3.2.3
> > > 10:14:06,589  INFO Environment:542 - hibernate.properties not found
> > > 10:14:06,596  INFO Environment:676 - Bytecode provider name : cglib
> > > 10:14:06,600  INFO Environment:593 - using JDK 1.4
> > > java.sql.Timestamphandling
> > > 10:14:06,685  INFO Configuration:1426 - configuring from resource:
> > > /hibernate.cfg.xml
> > > 10:14:06,686  INFO Configuration:1403 - Configuration resource:
> > > /hibernate.cfg.xml
> > > 10:14:06,783  INFO Configuration:553 - Reading mappings from resource
> > > :
> > > Namespace.hbm.xml
> > > 10:14:06,966  INFO HbmBinder:300 - Mapping class: Namespace ->
> > > biodatabase
> > > [...]
> > > Exception in thread "main" java.lang.RuntimeException: Error while
> > > trying to
> > > save RichSequence with id: CAK20891
> > >     at
> > > org.biojavax.bio.db.biosql.BioSQLRichSequenceDB._addRichSequence(
> > > BioSQLRichSequenceDB.java:300)
> > >     at org.biojavax.bio.db.biosql.BioSQLRichSequenceDB.addRichSequence
> > > (
> > > BioSQLRichSequenceDB.java:277)
> > >     at fr.ustrasbg.ibmc.bbeckert.HibernatLoadingData.loadingData(
> > > HibernatLoadingData.java:101)
> > >     at fr.ustrasbg.ibmc.bbeckert.HibernatLoadingData.main(
> > > HibernatLoadingData.java:140)
> > >     at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
> > >     at sun.reflect.NativeMethodAccessorImpl.invoke(
> > > NativeMethodAccessorImpl.java:39)
> > >     at sun.reflect.DelegatingMethodAccessorImpl.invoke(
> > > DelegatingMethodAccessorImpl.java:25)
> > >     at java.lang.reflect.Method.invoke (Method.java:585)
> > >     at com.intellij.rt.execution.application.AppMain.main(AppMain.java
> > > :90)
> > > Caused by: java.lang.reflect.InvocationTargetException
> > >     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> > >     at sun.reflect.NativeMethodAccessorImpl.invoke(
> > > NativeMethodAccessorImpl.java:39)
> > >     at sun.reflect.DelegatingMethodAccessorImpl.invoke(
> > > DelegatingMethodAccessorImpl.java:25)
> > >     at java.lang.reflect.Method.invoke (Method.java:585)
> > >     at
> > > org.biojavax.bio.db.biosql.BioSQLRichSequenceDB._addRichSequence(
> > > BioSQLRichSequenceDB.java:297)
> > >     ... 8 more
> > > Caused by: org.hibernate.TransientObjectException: object references
> > > an
> > > unsaved transient instance - save the transient instance before
> > > flushing:
> > > Term
> > >     at
> > > org.hibernate.engine.ForeignKeys.getEntityIdentifierIfNotUnsaved(
> > > ForeignKeys.java:219)
> > >     at
> > > org.hibernate.collection.AbstractPersistentCollection.getOrphans (
> > > AbstractPersistentCollection.java:889)
> > >     at org.hibernate.collection.PersistentSet.getOrphans(
> > > PersistentSet.java
> > > :90)
> > >     at org.hibernate.engine.CollectionEntry.getOrphans(
> > > CollectionEntry.java
> > > :350)
> > >     at org.hibernate.engine.Cascade.deleteOrphans(Cascade.java:340)
> > >     at org.hibernate.engine.Cascade.cascadeCollectionElements(
> > > Cascade.java
> > > :324)
> > >     at org.hibernate.engine.Cascade.cascadeCollection(Cascade.java:242)
> > >     at org.hibernate.engine.Cascade.cascadeAssociation(Cascade.java
> > > :219)
> > >     at org.hibernate.engine.Cascade.cascadeProperty(Cascade.java:169)
> > >     at org.hibernate.engine.Cascade.cascade(Cascade.java:130)
> > >     at
> > > org.hibernate.event.def.AbstractSaveEventListener.cascadeAfterSave(
> > > AbstractSaveEventListener.java:456)
> > >     at
> > >
> > > org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate
> > > (
> > > AbstractSaveEventListener.java :334)
> > >     at org.hibernate.event.def.AbstractSaveEventListener.performSave(
> > > AbstractSaveEventListener.java:181)
> > >     at
> > > org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId
> > > (AbstractSaveEventListener.java :107)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.saveWithGeneratedOrRequestedId
> > > (DefaultSaveOrUpdateEventListener.java:187)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.entityIsTransient(
> > > DefaultSaveOrUpdateEventListener.java:172)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.performSaveOrUpdate
> > > (DefaultSaveOrUpdateEventListener.java:94)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.onSaveOrUpdate(
> > > DefaultSaveOrUpdateEventListener.java:70)
> > >     at org.hibernate.impl.SessionImpl.fireSaveOrUpdate(
> > > SessionImpl.java:507)
> > >     at org.hibernate.impl.SessionImpl.saveOrUpdate(SessionImpl.java
> > > :499)
> > >     at org.hibernate.engine.CascadingAction$1.cascade (
> > > CascadingAction.java
> > > :218)
> > >     at org.hibernate.engine.Cascade.cascadeToOne(Cascade.java:268)
> > >     at org.hibernate.engine.Cascade.cascadeAssociation(Cascade.java
> > > :216)
> > >     at org.hibernate.engine.Cascade.cascadeProperty (Cascade.java:169)
> > >     at org.hibernate.engine.Cascade.cascade(Cascade.java:130)
> > >     at
> > > org.hibernate.event.def.AbstractSaveEventListener.cascadeBeforeSave(
> > > AbstractSaveEventListener.java:431)
> > >     at
> > >
> > > org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(
> > > AbstractSaveEventListener.java:265)
> > >     at org.hibernate.event.def.AbstractSaveEventListener.performSave(
> > > AbstractSaveEventListener.java:181)
> > >     at
> > > org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId
> > > (AbstractSaveEventListener.java:107)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.saveWithGeneratedOrRequestedId
> > > (DefaultSaveOrUpdateEventListener.java:187)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.entityIsTransient(
> > > DefaultSaveOrUpdateEventListener.java:172)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.performSaveOrUpdate
> > > (DefaultSaveOrUpdateEventListener.java:94)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.onSaveOrUpdate(
> > > DefaultSaveOrUpdateEventListener.java:70)
> > >     at org.hibernate.impl.SessionImpl.fireSaveOrUpdate(
> > > SessionImpl.java:507)
> > >     at org.hibernate.impl.SessionImpl.saveOrUpdate(SessionImpl.java
> > > :499)
> > >     at org.hibernate.engine.CascadingAction$1.cascade (
> > > CascadingAction.java
> > > :218)
> > >     at org.hibernate.engine.Cascade.cascadeToOne(Cascade.java:268)
> > >     at org.hibernate.engine.Cascade.cascadeAssociation(Cascade.java
> > > :216)
> > >     at org.hibernate.engine.Cascade.cascadeProperty (Cascade.java:169)
> > >     at org.hibernate.engine.Cascade.cascade(Cascade.java:130)
> > >     at
> > > org.hibernate.event.def.AbstractSaveEventListener.cascadeBeforeSave(
> > > AbstractSaveEventListener.java:431)
> > >     at
> > >
> > > org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(
> > > AbstractSaveEventListener.java:265)
> > >     at org.hibernate.event.def.AbstractSaveEventListener.performSave(
> > > AbstractSaveEventListener.java:181)
> > >     at
> > > org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId
> > > (AbstractSaveEventListener.java:107)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.saveWithGeneratedOrRequestedId
> > > (DefaultSaveOrUpdateEventListener.java:187)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.entityIsTransient(
> > > DefaultSaveOrUpdateEventListener.java:172)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.performSaveOrUpdate
> > > (DefaultSaveOrUpdateEventListener.java:94)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.onSaveOrUpdate(
> > > DefaultSaveOrUpdateEventListener.java:70)
> > >     at org.hibernate.impl.SessionImpl.fireSaveOrUpdate(
> > > SessionImpl.java:507)
> > >     at org.hibernate.impl.SessionImpl.saveOrUpdate(SessionImpl.java
> > > :499)
> > >     at org.hibernate.engine.CascadingAction$1.cascade (
> > > CascadingAction.java
> > > :218)
> > >     at org.hibernate.engine.Cascade.cascadeToOne(Cascade.java:268)
> > >     at org.hibernate.engine.Cascade.cascadeAssociation(Cascade.java
> > > :216)
> > >     at org.hibernate.engine.Cascade.cascadeProperty (Cascade.java:169)
> > >     at org.hibernate.engine.Cascade.cascadeCollectionElements(
> > > Cascade.java
> > > :296)
> > >     at org.hibernate.engine.Cascade.cascadeCollection(Cascade.java
> > > :242)
> > >     at org.hibernate.engine.Cascade.cascadeAssociation (Cascade.java
> > > :219)
> > >     at org.hibernate.engine.Cascade.cascadeProperty(Cascade.java:169)
> > >     at org.hibernate.engine.Cascade.cascade(Cascade.java:130)
> > >     at
> > > org.hibernate.event.def.AbstractSaveEventListener.cascadeAfterSave (
> > > AbstractSaveEventListener.java:456)
> > >     at
> > >
> > > org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate
> > > (
> > > AbstractSaveEventListener.java:334)
> > >     at org.hibernate.event.def.AbstractSaveEventListener.performSave (
> > > AbstractSaveEventListener.java:181)
> > >     at
> > > org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId
> > > (AbstractSaveEventListener.java:107)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.saveWithGeneratedOrRequestedId
> > > (DefaultSaveOrUpdateEventListener.java:187)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.entityIsTransient
> > > (
> > > DefaultSaveOrUpdateEventListener.java:172)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.performSaveOrUpdate
> > > (DefaultSaveOrUpdateEventListener.java:94)
> > >     at
> > >
> > > org.hibernate.event.def.DefaultSaveOrUpdateEventListener.onSaveOrUpdate
> > > (
> > > DefaultSaveOrUpdateEventListener.java:70)
> > >     at org.hibernate.impl.SessionImpl.fireSaveOrUpdate (
> > > SessionImpl.java:507)
> > >     at org.hibernate.impl.SessionImpl.saveOrUpdate(SessionImpl.java
> > > :499)
> > >     ... 13 more
> > > --
> > > Bertrand BECKERT
> > > PhD student
> > > IBMC - UPR 9002 du CNRS - ARN
> > > 15, rue Rene Descartes
> > > F-67084 STRASBOURG Cedex
> > >
> > > b.beckert at ibmc.u-strasbg.fr
> > > bertrand.beckert at gmail.com
> > > _______________________________________________
> > > Biojava-l mailing list  -  Biojava-l at lists.open-bio.org
> > > http://lists.open-bio.org/mailman/listinfo/biojava-l
> > >
> >
> >
> >
> > --
> > Farewell.
> > http://www.youtube.com/zagatogekko
> > ruby << __EOF__
> >   puts [ 111, 116, 97, 103, 97, 90 ].collect{|v| v.chr}.join.reverse
> > __EOF__
>
>
>
>
> --
> Bertrand BECKERT
> PhD student
> IBMC - UPR 9002 du CNRS - ARN
> 15, rue Rene Descartes
> F-67084 STRASBOURG Cedex
>
> b.beckert at ibmc.u-strasbg.fr
> bertrand.beckert at gmail.com
>



-- 
Farewell.
http://www.youtube.com/zagatogekko
ruby << __EOF__
  puts [ 111, 116, 97, 103, 97, 90 ].collect{|v| v.chr}.join.reverse
__EOF__



More information about the Biojava-l mailing list