Hello Thanks for the link , But in the discussion , there is no solution , it just say that we need to convert Jdbc types ... Any guess about when we will have a correction ?. B.R Thierry
-----Original Message----- From: Andy Malakov [mailto:[EMAIL PROTECTED] Sent: Thursday, January 22, 2004 10:51 PM To: OJB Users List Subject: Re: Pbm on MtoNCollectionPrefetcher Hello Thierry, Here is comment of Jakob Braeuchi in OJB-DEV on the same issue : http://article.gmane.org/gmane.comp.jakarta.ojb.devel/5084 ----- Original Message ----- From: "Thierry Hanot" <[EMAIL PROTECTED]> To: "'OJB Users List'" <[EMAIL PROTECTED]> Sent: Thursday, January 22, 2004 3:31 PM Subject: Pbm on MtoNCollectionPrefetcher > Hello > There is a problem on the MtoNCollectionPrefetcher . > > Description : > > Input a MtoN relation in an Oracle database > All the ids are SQL NUMBER and are declared as BIGINT in the repository.xml. > > The problem is that the Prefetecher use a ReportQuery in the method > prefetchRelationship but use the class descriptor ( in the > associateBatched method ) for generating identity . > > Identity on Object A using the ReportQuery : 2 BigInteger ( using the > JdbcTypesHelper and the MetaDatas of the statement ) Identity on > Object A using the ClassDescriptor : 2 Long > > The equal method of the identity return false even with the same ids > ... So access to the maps childMap and ownerIdsToLists ( in > associateBatched > ) cause NPE because returning null values . > > I think may be the mapping of the good type of the ReportQuery result > is missing ??? > > > > Here is a part of the stack : > > > org.apache.ojb.broker.accesslayer.MtoNCollectionPrefetcher.associateBa > tched( > MtoNCollectionPrefetcher.java:363) > at > org.apache.ojb.broker.accesslayer.MtoNCollectionPrefetcher.prefetchRelations > hip(MtoNCollectionPrefetcher.java:126) > at > org.apache.ojb.broker.core.QueryReferenceBroker$PBPrefetchingListener.prefet > ch(QueryReferenceBroker.java:837) > at > org.apache.ojb.broker.core.QueryReferenceBroker$PBCollectionProxyListener.be > foreLoading(QueryReferenceBroker.java:894) > at > org.apache.ojb.broker.accesslayer.CollectionProxy.beforeLoading(CollectionPr > oxy.java:173) > at > org.apache.ojb.broker.accesslayer.CollectionProxy.getData(CollectionProxy.ja > va:400) > at > org.apache.ojb.broker.accesslayer.CollectionProxy.iterator(CollectionProxy.j > ava:230) > > > B.R > > > Thierry > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
