Re: Join many to many problem
Re: Join many to many problem
- Subject: Re: Join many to many problem
- From: Buyung Pamungkas <email@hidden>
- Date: Thu, 27 Feb 2003 20:27:04 -0800 (PST)
it's great! thank you very much :) it really help me
:)
I've notice Programmer.task relationship and
Task.programmer relationship. But I hadn't know how to
use it :) until I read this solution :)
---
Subject: Re: Join many to many problem
From: Art Isbell <email@hidden>
To: email@hidden
The join entity, in your situation and many others, is
really an
abstract entity that shouldn't be accessed at all.
Because you have
the flattened relationships Programmer.tasks and
Task.programmers, you
can't access ProgrammerTask from either Programmer or
Task. So don't
try to insert an object into ProgrammerTask.
Instead, avoid thinking about the relational database
and think about
what you'd do in the object world and let EOF manage
the relational
database. Add the Task "coding" object to the
Programmer "Buyung"
object's "tasks" relationship:
buyungProgrammer.addObjectToBothSidesOfRelationshipWithKey(codingTask,
"tasks")
Then save the editing context. Voila!
Art
http://homepage.mac.com/aisbell/
=====
-Buyung-
YahooID = buyung_pamungkas
ICQ# = 159587929
Yahoo! Tax Center - forms, calculators, tips, more
http://taxes.yahoo.com/
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.