Hi all! [mehmet.sariyar@rizit.at @ 04.01.07:18:12:43 wrote]

Although tried any modifications described in the "how-to's", I wasn't already able to build up an inheritance using concept of setting superclasses primary-key as primary-and-foreign-key of the subclass. Everything is well functioning, the primitive fields of the superclass are loaded together with the loaded subclass. BUT reference-descriptors and collection-descriptiors described in the super-class will be ignored, not give damn about them!

Here a look-like :

<class-descriptor class="A" table="A">

                          autoincrement="true"/> 

</class-descriptor>

<class-descriptor class="B" table="B">

</class-descriptor>

Does anyone have any experience with CONCEPT#3 of Inheritance O/R-Mapping ?

Please mail to address above.

;-)_


_(-;

Hello,

Simple question - not sure if it's answered in OJB docs or this Wiki (if so, I can't find it or don't understand it).

I'd like to know if OJB supports both:

1) Taking a set of Java classes and generating DDL (and optionally mapping)

2) Taking a schema (DDL) and generating corresponding Java classes (and optionally mapping)

Please send answers to robertprince99@yahoo.com

Thanks! :)


Hi

I want to know if I can do the following example :

class C{

} {{{ public int getVal() { return val; }

}

class B{

}

} class A{

}

I want to map the C object 3 times like this : · One BC table for the C object in the B.l1 list, · One AC1 table for the C object in the C.l1 list, · One AC2 table for the C object in the C.l2 list.

Is it possible, if not how to do it ?


I do the following enhance,but nothing happend! platform: {{{ jdori 1.0.1 (9/22/2003)

java -classpath jdo\jdo.jar;do\jdori.jar;jdo\jdori-enhancer.jar;energy\data;.; com.sun.jdori.enhancer.Main -v -f -d enhanced Project energy.jdo energy\data\Project.class Enhancer: options: {{{ verbose = true

JDO ENHANCER: using file: file:/C:/Data/project/energy/data/classes/energy/data/Project.class Class Locator: using class files: {     energy\data\Project.class  } JDO ENHANCER: using file: file:/C:/Data/project/energy/data/classes/energy.jdo


JDO ENHANCER: Enhancer: enhancing classfile ... JDO ENHANCER: scanning class energy.data.Project JDO ENHANCER: not found resource: META-INF/package.jdo JDO ENHANCER: not found resource: WEB-INF/package.jdo JDO ENHANCER: not found resource: package.jdo JDO ENHANCER: not found resource: energy/package.jdo JDO ENHANCER: not found resource: energy/data/package.jdo JDO ENHANCER: not found resource: energy/data/Project.jdo JDO ENHANCER: has default constructor. JDO ENHANCER: has not static initializer. JDO ENHANCER: has not clone method. JDO ENHANCER: has not writeObject method. JDO ENHANCER: has not writeReplace method. JDO ENHANCER: has not readObject method. JDO ENHANCER: annotating class energy.data.Project JDO ENHANCER: annotating: energy.data.Project.getId() JDO ENHANCER: annotating: energy.data.Project.setName(java.lang.String) JDO ENHANCER: annotating: energy.data.Project.<init>() JDO ENHANCER: annotating: energy.data.Project.getName() JDO ENHANCER: annotating: energy.data.Project.setId(java.lang.String) JDO ENHANCER: no changes to class energy.data.Project

JDO ENHANCER: Enhancer: classfile not changed. JDO ENHANCER: found resource: Project.class


JDO ENHANCER: Enhancer: enhancing classfile ... JDO ENHANCER: scanning class energy.data.Project JDO ENHANCER: has default constructor. JDO ENHANCER: has not static initializer. JDO ENHANCER: has not clone method. JDO ENHANCER: has not writeObject method. JDO ENHANCER: has not writeReplace method. JDO ENHANCER: has not readObject method. JDO ENHANCER: annotating class energy.data.Project JDO ENHANCER: annotating: energy.data.Project.getId() JDO ENHANCER: annotating: energy.data.Project.setName(java.lang.String) JDO ENHANCER: annotating: energy.data.Project.<init>() JDO ENHANCER: annotating: energy.data.Project.getName() JDO ENHANCER: annotating: energy.data.Project.setId(java.lang.String) JDO ENHANCER: no changes to class energy.data.Project

JDO ENHANCER: Enhancer: classfile not changed. done.


OJB JDO implementation seems confict with JDORI 1.0.1

objfiledmanager and objstoremanager in package org.apache.ojb.jdori.sql; need some changes(because sun rmi 1.0.1? maybe it need sun rmi 1.0)


When should we use OJB in a J2EE EJB application? (Presumably we can use OJB as Bean Managed Persistence and an alternative to Container Managed Persistence - but is that a good idea?)


Hello everybody. I have a little problem with this OJB-code:

{{{ String sql = "SELECT MAX(ID)FROM Userdata ";

The data is always null. What is the mistake in this code ?


Hey!

I'm working with OJB on two Relations! Lets call them A and B! When I try to store an Object in one of these 2 Relations I Sometimes get an

org.apache.ojb.broker.OptimisticLockException: Object has been modified by someone else

Exception. When do I recieve this Exception, I can't find an satisfying API for this Exception!

After making some TestRuns I found out: either I can store Objects in Relation A or I can store an Object in Relation B. Trying to store something in the other Relation always gives me the OptimisticLockException!

Object/Relation A has been 1:n-ojb-mapped to Object/Relation B! I removed this mapping, but it wasn't the solution...

My Store-Methode:

public Object storeObject(Object o) {

any solutions? thx

--> oh, seems like I found a solution: in the OJB.properties I have to activate ObjectCacheClass=org.apache.ojb.broker.cache.ObjectCachePerBrokerImpl


Some personal experiences

Hi, I tried to set up OJB on RH9.0 with MySQL. It's not really, really straightforward if you know what I mean. Sorry if I come across as an ***hole, but, people, the first build/deploy *must* work without problems or headaches otherwise people will just wander off to another project in 60 seconds. Put it on the to-do-list! Well, it probably already is.

d.tonhofer@m-plify.com

We follow the instructions in the http://db.apache.org/ojb/howto-get-started.html<br>

Download the source distribution using

   $ wget http://db.apache.org/builds/ojb/1.0.rc4/db-ojb-1.0.rc4-src.tgz 

and put it into /usr/local/tarballs

Edit build.properties. Comment out profile=hsqldb and uncomment profile=mysql

Edit ./profile/mysql.profile. We have created a test database called toon_xp_tests to which user test can connect from anywhere. Thus, set the databaseUser to test, set the databasePassword. According to the createDatabaseUrl, the new database will be called ojb. We change this to toon_xp_tests. Do *not* change the value of database (which is mysql). It's just an arbitrary name.

Now run ant junit.

This is a headfull junit test! It needs X11! I'm on the text console! Foo! Barfulation!

Kill references to project splash from build.xml.

The compilation is still not gonna work. It wants j2ee.... This is incomprehensible.

Drop this problem for now. We might want to come back to it later.

Try the Tutorial

Get the binary release. Then try to work through the tutorials.

Prepare build.properties and ./profile/mysql.profile as decribed above.

Then prepare the Tutorials:

  $ source bin/build.sh prepare-tutorials > OUT 2>&1 

All the errors will now be collected in OUT

Again, we get the splash screen problem. You know what to do (see above). We then get a complaint that j2ee cannot be found. Remove the reference to the check-j2ee-classes in the main depends list. Run the build.sh again.

Then we get:

{{{ BUILD FAILED

JCA is (presumably) the Java Cryptography Architecture. What is this about??

Comment out the JCA block in build.xml, i.e.

{{{ <!--

You can just create the directory db-ojb-1.0.rc4/src/jca, this will fix this particular problem.

Ok, fixed that. Build proceeds, but now we have:

{{{ java.sql.SQLException: Syntax error or access violation, message from

Seems that the variable @DATABASE_DEFAULT@ is not correctly replaced? Siiigghhh!

So we do that manually.

{{{ $ grep -R 'DATABASE_DEFAULT'*

This is sucky. There probably should be something in the ant project that does the replacement?

Here we go again:

{{{ $ source bin/build.sh prepare-tutorials


dmagdali@calpoly.edu

Completely agree with the previous poster. Had the exact same experience except on windows. Also, are these problems new to 1.0rc4? Why are only downloads for the new 1.0.rc* builds available? Why are there no stable versions available?

OJBProjectPages/YourQuestionHere (last edited 2009-09-20 22:56:09 by localhost)