There are some aspects of OJB that require/encourage having two pieces of
data to represent single relationship.
1) When I have an referenceDescriptor, I have to have a fooOid, and a Foo,
both of which are two ways of referring to the same thing.
2) When I have a collectionDescriptor, I have a
The issue isn't the presence of the record in the table. It's the presence on the
newImport of an Lu_process_status object which represents the Q record in the
database.
When you store newImport, ojb looks at the content of newImport to figure out what
values to use in the sql statement. In
Hi David,
Application code should (never?) touch the fooOid, only the referred Foo
objects should be manipulated. Likewise for the collections and their
parent object id. OJB does the underlying synchronization for you.
But maybe you have some special conditions that sometime require you to
Another helpful thing to know is that
PersistenceBroker.retrieveReferences(myObject) will automatically update
any reference objects attached to myObject from the corresponding
foreign key ID fields.
-Original Message-
From: C F [mailto:[EMAIL PROTECTED]
Sent: Tuesday, March 04, 2003
Hi Charles,
Thanks for the detailed answer. That does the job nicely. We had moved
from an m:n relationship and were somewhat blinded by the fact that we
hadn't been using the association table directly (we had used it as an
'indirection-table').
Thanks again,
John
-Original Message-
Hello,
I am currently building a web application based on Tomcat and Struts, using
the Eclipse IDE.
Trying to use OJB as the persistence layer, I have the following problem :
The OJB spec. requires that the config files (OBJ.properties,
repository.xml...) be retrieved from the classpath,
which
Philippe,
Change your eclipse build directory from /WEB-INF/classes to /classes.
-chris worley
Hello,
I am currently building a web application based on Tomcat and Struts, using
the Eclipse IDE.
Trying to use OJB as the persistence layer, I have the following problem :
The OJB spec. requires
Hi Adam,
The message you see is not lying! You really have to place j2ee.jar into
your classpath.
The OJB dependencies are listed here:
http://db.apache.org/ojb/dependencies.html
cheers,
Thomas
Adam Griffiths wrote:
Hi,
I just downloaded db-ojb-1.0.rc1-src.tgz and db-ojb-1.0.rc1.tgz and
I absolutely agree with Charles!
the automatic handling of foreign keys was build to let developers
concentrate on business objects and not on rdbms details.
Thomas
Charles Anthony wrote:
Hi,
Developer should only ever set foo, and should never set fooId.
OJB manages all foreign keys.
In
Hi Philippe,
just place OJB.properties into the root of your source folder. it will
be copied to WEB-INF/classes by eclipse automatically on a complete build.
chers,
Thomas
[EMAIL PROTECTED] wrote:
Hello,
I am currently building a web application based on Tomcat and Struts, using
the Eclipse
Hi Joerg,
I'm not quite sure if I got your question.
Are you asking if the field-descriptors for name and number must be
present in the class-descriptors for the concrete classes, or if it is
possible to just define them once in the base-classes descriptor?
The answer to this question is:
Hi David,
The testsuite has been tested against HSQLDB only. So it's quite
possible that certain special thing fail for certain other platforms.
This is normally nothing to worry about. Not all RDBMS/JDBC drivers
support all possible features.
Just have a look at the log files in target/test
Hi Dennis,
Dennis Ryan wrote:
I dont know who is responsible for these things,
I shouldn't admit it, but it's usually me...
but I have what i think is
a minor request. What i'd like, and what i think would be useful to others
is a html formatted junit report. The plaintext output in my opinion
Hi Joerg,
Joerg Lensing wrote:
Hi,
junit: Article - Produktgroup
Article holds an ID from Productgroup. In the example it is the
primaryKey from table Kategorien.
foreign keys from one table alway reference primary keys of another (or
the same in case of self-join) table.
Can I use different
Phillipe,
I keep my repository*.xml files in WEB-INF/src, and eclipse seems to
copy them over to WEB-INF/classes for me. I also use the Sysdeo Tomcat
plugin, which may be what's actually helping me out.
HTH,
Colin
[EMAIL PROTECTED] wrote:
Hello,
I am currently building a web application
But if OJB is deployed on a J2EE application server, we don't have to
specificly add j2ee.jar into classpath. Right?
Lucy
-Original Message-
From: Thomas Mahler [mailto:[EMAIL PROTECTED]
Sent: Tuesday, March 04, 2003 2:18 PM
To: OJB Users List
Subject: Re: Does db-ojb-1.0.rc1.tgz depend
Hi all,
One other thing to maybe mention about Charles' example is that
the PROJECTRELATIONSHIP table has a composite primary key consisting of
DEVELOPER_ID, LANGUAGE_ID and PROJECT_ID. I didn't see this in the
repository extract.
Phil
Thomas Mahler wrote:
Hi Charles,
thanks for the good
Hi Thomas,
This may be a bit off topic
I use OJB exclusively in a web application environment. When a web form
posts to one of my actions I only pass the ids of any dependent objects
(from a list box etc...). I would like to set this id on my target
object and then store it. Of course,
I'm trying to do something like:
select * from contributions where last_activity = '2003-03-04
14:35:38';
but using this:
criteria.addGreaterOrEqualThanField(lastActivity, date); or
criteria.addGreaterOrEqualThanField(lastActivity,
formatter.format(date));
doesn't work. Any ideas?
--Scott
I forgot to mention I'm running 0.9.9. Here is a little more info. From
my log:
[17:08:04,955,OJBORMManager] DEBUG save: class=common.model.Note
[17:08:04,955,OJBORMManager] DEBUG save:
o=[Note:id=59,code=NOTE79,subcode=foo,ident=ID2564,desc=this is a debug
note,ownerId=74,docId=16]
I only wish to map a the objects of a standalone application to a local
database. Is j2ee still required for me? I don't think I need and j2ee
functionality. Am I mistaken?
Many thanks
Adam
s_p_a_m_t_r_a_p from:[EMAIL PROTECTED]
Do
Thanks Thomas. I went ahead and attempted to deploy anyhow, but now I get
the following error:
Class org/xml/sax/ContentHandler violates loader constraints
Here's the whole output - pls let me know if you see anything familiar:
system-errjava.lang.LinkageError: Class
I was trying to upgrade from 0.9.6 to 1.0rc1. When I startup the webapp, it give me
the following error
[BOOT] ERROR: Error in instantiation of PersistenceBrokerFactory class
Could not read repository class descriptor data, using repository: repository.xm
l: Class
Hi Adam
It's a compiletime depency. So if your application does not use any J2EE
features there's no problem at runtime without that jar file.
cheers,
Thomas
Adam Griffiths wrote:
I only wish to map a the objects of a standalone application to a local
database. Is j2ee still required for me? I
24 matches
Mail list logo