• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Multiple Self-joins
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Multiple Self-joins


  • Subject: Re: Multiple Self-joins
  • From: David Holt <email@hidden>
  • Date: Wed, 12 Jan 2005 12:12:28 -0800

Thanks Chuck,

I wasn't thinking clearly about the FKs. I was joining on imageID>imageID in both cases. That make no sense whatsoever. So now I have the to-one relationships cleared up. How do I implement the to-many self join? I have made a to-one between parentFK>imagePK. Where does the to-many relationship sit? Is there a link table?

I do not understand your suggestion for reordering the images. They are process flows, so I could see having to reorder them in the future. In fact it is guaranteed. Is there a resource that I could read to help me understand what you are talking about?

On 12 Jan 2005, at 11:55 AM, Chuck Hill wrote:

On Jan 12, 2005, at 11:49 AM, David Holt wrote:

Hi Chuck,

I can create a to-one relationship (named parentImage) and a to-many relationship (named childrenImages) linked on the primary key of the image table.
Linked to what?

When I go to create an additional to-one relationship (nextImage or previousImage),
Linking what to what?

the inspector in EOModeler shows the entities as already being connected by their primary keys and the button is labelled "disconnect". There is no way to create additional relationships using the same primary keys without disconnecting the previous relationship as far as I can tell.

Of course not. The same thing can't be different things at the same time. Draw it out on a piece of paper. You need

pk
parentFK (PK value, but a FK in use)  -> for parentImage, childImages
previousFK -> for previousImage
nextFK -> for nextImage

You might want to forget about the previousFK and nextFK and just use an order column and make previous and next image methods on the parent. It will be a lot easier to reorder like that.

_______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Follow-Ups:
    • Re: Multiple Self-joins
      • From: Chuck Hill <email@hidden>
References: 
 >Re: Multiple Self-joins (From: Chuck Hill <email@hidden>)
 >Re: Multiple Self-joins (From: David Holt <email@hidden>)
 >Re: Multiple Self-joins (From: Chuck Hill <email@hidden>)

  • Prev by Date: Re: Multiple Self-joins
  • Next by Date: Re: Multiple Self-joins
  • Previous by thread: Re: Multiple Self-joins
  • Next by thread: Re: Multiple Self-joins
  • Index(es):
    • Date
    • Thread