Re: Implementing Single Table Aggregation in OJB

2003-03-13 Thread Joerg Lensing
Lynn Monson schrieb: Could anyone tell me how to implement the Single Table Aggregation pattern for a 1:1 relation using OJB? RowReaders seem to solve the problem for reading, but I'm stumped as to how to write to such a table. The pattern is found here: http://www.objectarchitects.de/ObjectArch

Re: Please help: argument type mismatch at PersistenceBroker.getCollectionByQuery()

2003-03-13 Thread shivaken
Ok, my class works, after change JDBC-TYPE from FLOAT to REAL. I will take care of these type mapping. Thank you. On Friday 14 March 2003 16:17, Thomas Mahler wrote: > JDBC FOLAT mapps to Java "double", not to Java "float" ! > > See: http://db.apache.org/ojb/jdbc-types.html -- shivaken ant c

RE: Transactional isolation at the object layer

2003-03-13 Thread Lance Eason
Beautiful, thanks. I'm loving OJB so far. -Original Message- From: Thomas Mahler [mailto:[EMAIL PROTECTED] Sent: Friday, March 14, 2003 1:15 AM To: OJB Users List Subject: Re: Transactional isolation at the object layer Hi Lance, By default OJB uses one large global cache. To achieve p

Re: Please help: argument type mismatch at PersistenceBroker.getCollectionByQuery()

2003-03-13 Thread Thomas Mahler
JDBC FOLAT mapps to Java "double", not to Java "float" ! See: http://db.apache.org/ojb/jdbc-types.html shivaken wrote: With a float, PersistenceBroker.getCollectionByQuery() throws MetaDataException Accouding to stack trace, The error's reason is treating value as double instead of float when

Re: Transactional isolation at the object layer

2003-03-13 Thread Thomas Mahler
Hi Lance, By default OJB uses one large global cache. To achieve proper isolation you have to tell OJB to use one cache per Broker: In OJB.properties you have to configure to use org.apache.ojb.broker.cache.ObjectCachePerBrokerImpl as objectcache implementation cheers, Thomas Lance Eason wrote:

Re: Implementing Single Table Aggregation in OJB

2003-03-13 Thread Thomas Mahler
Hi Lynn, You have to tell OJB to use a PersistenField implementation supporting this in OJB.properties first, as it is not yet implemented in the default implementation: PersistentFieldClass=org.apache.ojb.broker.metadata.fieldaccess.PersistentNestedFieldMaxPerformanceImpl if your class has an

Please help: argument type mismatch at PersistenceBroker.getCollectionByQuery()

2003-03-13 Thread shivaken
With a float, PersistenceBroker.getCollectionByQuery() throws MetaDataException Accouding to stack trace, The error's reason is treating value as double instead of float when invoking setFee(float fee). I wonder that is from wrong configuration. Then I made a test with a very similar object. B

Re: OJB 0.9.9 and Oracle 817 always rollback

2003-03-13 Thread Thomas Phan
Hi, I tried 0.9.8, but it doesn't work as well! Running Jetty: - Initializing, config='org.apache.struts.util.LocalStrings', returnNull=true - Initializing, config='org.apache.struts.action.ActionResources', returnNull=true - Initializing, config='com.entersys.escds.webapp.ApplicationResources',

Transactional isolation at the object layer

2003-03-13 Thread Lance Eason
I'm using 1.0 rc1 with the PB API. I'm noticing that I don't have any isolation between multiple brokers when caching is enabled. For example: Object[] pk = new Object[] {new Long(42)}; Identity id = new Identity(Article.class, pk); PersistenceBroker broker1 = PersistenceBrokerFactory

Implementing Single Table Aggregation in OJB

2003-03-13 Thread Lynn Monson
Could anyone tell me how to implement the Single Table Aggregation pattern for a 1:1 relation using OJB? RowReaders seem to solve the problem for reading, but I'm stumped as to how to write to such a table. The pattern is found here: http://www.objectarchitects.de/ObjectArchitects/orpatterns/M

Primary Key problem

2003-03-13 Thread Jason McKerr
I'm still using 0.9.8 and I'm having a primary key issue. I put a record into the database (Oracle) through a SQL client, and just fill in the primary key. Then when I start up and do a select, the primary key that is being shown is one that is generated by OJB, even though the one in the databas

exception thrown when autobuild is used with mysql

2003-03-13 Thread TH Lim
Hi, I am testing OJB's tutorial 5 using OJB ver 1.0-RC1 to persist to MySQL ver. 3.23.54 with MySQL JDBC driver ver. 3.0.6. All is fine until I set autobuild property to true. Once I have set this, I am thrown a connection closed exception. The detail of the exception is as shown below [JDO] DEBUG

ODMG bind() equivelant for PersistenceBroker?

2003-03-13 Thread C F
Probably a dumb question but. is there something like query.bind() that I can with PB? I want to use PB because it seems more flexible but I *really* like being able to create a query and use bind() like I can with ODMG. Thanks - Do you Yahoo!? Yahoo! Web

Re: Interesting (failing) scenario of FKs/PKs in PB

2003-03-13 Thread Jakob Braeuchi
hi all, i fixed this problem by assigning the foreign keys when the first check fails. after this assignement i do another check which MUST be successful otherwise an PersistenceBrokerException is thrown. so it no longer dies silently. the reason i do this two step approach is that i'm not sur

RE: locking and sql server..(was 'is this an old .97 bug?')

2003-03-13 Thread Ryan Vanderwerf
Just a follow up to this... setting the isolation level to 'serializable' does no good for preventing SequenceGenerator from giving out duplicate sequences when running multiple servlet engines on the same database (Using SQL server). In theory it should, but it doesn't. 2 App servers can read the

Re: OJB 0.9.9 and Oracle 817 always rollback

2003-03-13 Thread Thomas Phan
Hi Really? I attempted to try 0.9.8, but I found that my code has used some 0.9.9 APIs; couldn't even start an ODMG instance. I think there may be a bug in reading the result set. I tried that there's no problem if the returning query is empty For DB2 connection, do you use jdbc-level="1.0"? I th

migrating Torque to OJB

2003-03-13 Thread Eric Emminger
I'm evaluating migrating from Torque to OJB. Can anyone provide any experience, feedback, suggestions, time estimates, etc on doing this? Eric - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL

Multiples jdbc-connection-descriptor ??

2003-03-13 Thread Emmanuel Dupont
All, I would like to have different declaration for different jcd-alias. But each time I try to put a second one, I have the error in websphere : "The markup in the document following the root element must be well formatted". I don't understand ?? I also wonder how to call the specific jc

Detecting constraint violations using ODMG

2003-03-13 Thread Yuji Shinozaki
I am in the process of junit-testing an application that is using the ODMG api. I am intentionally violating UNIQUE constraints in the junit tests for my application, and I am now trying to figure out how to handle the resultant exception: org.odmg.TransactionAbortedException: Batch entry 0 [Lja

Re: ODMG w/oracle problem

2003-03-13 Thread Larry Schuler
That's the strange part, I don't get a full null pointer exception traceback. As near as I can tell, the call to query.execute() silently returns a null with no other message. the code is straight from the examples (I think I actually cause the NullPointer later by trying to use the "rawResults"

RE: Object containing List of other objects

2003-03-13 Thread TINE Houari (OBJECTIVA)
Try this, For class B: add an attribute to model fk to A. public class B { private Integer id; private A a; private int fkToA; ... } and change class descriptor of B like this: Houar -Message d'origine- De :Peter Kirk [mailto:[EMAIL PROTECTED] Envoyé :jeudi 13 m

RE: Object containing List of other objects

2003-03-13 Thread TINE Houari (OBJECTIVA)
Try this, For class B: add an attribute to model fk to A. public class B { private Integer id; private A a; private int fkToA; ... } and change class descriptor of B like this: Houar -Message d'origine- De :Peter Kirk [mailto:[EMAIL PROTECTED] Envoyé

RE: Interesting (failing) scenario of FKs/PKs in PB

2003-03-13 Thread Malinescu, Cristian
Hi , Following advice of Armin, I changed in repository_database.xml eager-release="true" batch-mode="true" to eager-release="false" batch-mode="false" and now insert works for my Oracle 8 instance. Regards, Cristian -Original Message- From: Armin Waibel [mailto:[

workaorund for known sybase issue?, was: RE: Sybase: JZ0BE ...

2003-03-13 Thread oliver . matz
Hello again, > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > > The class has a lot of attributes. Maybe there is a size > limitation in sybase. We have found more information: this is sybase known issue #202534, see http://manuals.sybase.com/onlinebooks/

Object containing List of other objects

2003-03-13 Thread Peter Kirk
Hi there, I would be grateful if someone could take the time to look at this and tell me what I am doing incorrectly. I have an object A which contains a List of B objects. Each B object also contains the object A which owns it. I am trying to persist A via ODMG (and by persisting A I also want all

Antwort: Re: build.sh won't run -> FAQ suggestion

2003-03-13 Thread Carsten . Poertge
Thank you for the tip. Actually I solved it and have the build.sh runing, but I still don't know, why ... I had the same problem with the tutorial1.sh. Here is the case: When I start the skript, which is delivered with the OJB download: I get the following message: schnipp [EMAIL PROTECTED]:

Re: Why can't work for deploying OJB(db-ojb-1.0.rc1) to Jboss3.0.4?

2003-03-13 Thread Armin Waibel
Hi Dogie, we adopt a new concept to make the PBKey independent from the repository.xml, by using the 'jcd-alias' name in PBKey. Thus in your case you should do somthing like PBF.createPersistenceBroker(new PBKey("default")); or PBF.createPersistenceBroker(new PBKey("default", "sa", "passwd")); o

Re: OJB 0.9.9 and Oracle 817 always rollback

2003-03-13 Thread Guido Beutler
Hi, did you trie 0.9.8 ? I got the same problem with 0.9.9 and 1.0.rc1 and JBoss 3.0.4. with DB/2. 0.9.8 is working well for me. cheers, Guido - Original Message - From: "Thomas Phan" <[EMAIL PROTECTED]> To: "OJB Users List" <[EMAIL PROTECTED]>; "Armin Waibel" <[EMAIL PROTECTED]> Sent:

Newbie : OJB and multiple database ?

2003-03-13 Thread Emmanuel Dupont
All, 1) I am going to choose OJB for our new persistence implementation. I would like to how if it is possible for one JDO object (one .class object) to access to different databases ? It is possible by calling different factory, that it ? But what about the profile file and the

Newbie : OJB and multiple database ?

2003-03-13 Thread Emmanuel Dupont
All, 1) I am going to choose OJB for our new persistence implementation. I would like to how if it is possible for one JDO object (one .class object) to access to different databases ? It is possible by calling different factory, that it ? But what about the profile file and the

Is it possible to use OJB with Informix 7.31?

2003-03-13 Thread echevtchouk
Is there some information about somewone who tried OJB on Informix 7 ? Thanks to Domagoj Jugovic [EMAIL PROTECTED], with his informix profile for Torque i can launch the samples. However I am unable to create this ojb-core table on Informix 7.31: [torque-insert-sql] Failed to execute: CREATE TA