db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brian McCallister <mccallis...@forthillcompany.com>
Subject OTM Collection/Dependent Question
Date Fri, 10 Oct 2003 15:29:22 GMT
Working on an OTM tutorial and I have a fairly important question...

Foo and Bar are persistent classes

Foo contains a collection of Bar instances (collection is mapped)

You have an already persistent Foo which you queried for and you...

{
	tx.begin();
	Foo foo = findMyFoo(tx); // goes and gets a foo in context of the 
transaction
	Bar = new Bar();
	foo.addBar(bar);
	tx.commit()
}

Should bar be inserted?

-Brian



---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org


Mime
View raw message