Re: Coredata schema question.
Re: Coredata schema question.
- Subject: Re: Coredata schema question.
- From: Scott Stevenson <email@hidden>
- Date: Tue, 31 May 2005 22:14:44 -0700
On May 31, 2005, at 9:09 PM, James Andrews wrote:
My first question. I have a Categories Entity. I want to be able
to have categories that are children of categories. I am not sure
how to build a relationship for this. Suggestions on how to do it,
and explanations on why you would do it that way would greatly
appreciated.
Just create a relationship on Category with a target entity of
Category. It will point to itself.
I want to be able to link Photographs to Albums, and want to be
able to put the same image in multiple Albums. I had thought maybe
another Entity between Albums and Photographs, but I am not sure if
that would work the way I would expect it too.
Create a to-many relationship on Photograph that points to the Albums
entity (you probably actually want to call this "Album"). Core Data
will handle the rest.
- Scott
--
http://theocacao.com/
feed://theocacao.com/index.rss
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden