Context creation is fairly cheap; if you're really looking for
isolation of changes, you could create a new object context and
"localObject" the relevant objects into the new context.
Robert
On Mar 7, 2009, at 3/712:54 PM , Zissis Trabaris wrote:
It might be me not finding this in the documentation but here is the
question anyway. Given table A with a toMany relationship to table B,
it's obvious that when I get all instances of table B they share the
same context as table A. When making changes to a table B instance
and a
table A instance, I would like to be able to commit and rollback ONLY
table B's data. Since commitChanges() from the context's perspective
will commit changes to A and B, is there a way to isolate commits and
rollbacks to just one table? From what I understand, nested contexts
will not do this for me because if B was associated to a nested
context
of A's context, commitToParent() will not commit B's data to the
database until I run commitChanges() on A.
Any help here would be appreciated.
Zissis Trabaris * Chief Technology Officer * INSYSWARE * 3235 West
River
Road, Grand Island, New York, 14072, USA
Mobile (716) 930-5654 * Office (518) 636-4118 * Fax (716) 625-1305 *
[email protected] <mailto:%20%[email protected]> *
www.insysware.com <http://www.insysware.com/>
________________________________
CONFIDENTIALITY: This email (including any attachments) may contain
confidential, proprietary and privileged information, and unauthorized
disclosure or use is prohibited. If you received this email in error,
please notify the sender and delete this email from your system. Thank
you.