I'm not sure why you think that OQL can't join two entities with a
many-to-many relationship?  

The fact that Castor implements that through a many-table is an artifact of
the implementation.  The Castor implementation should hide this from the OQL
query.

- Mark

-----Original Message-----
From: florian ramillien [mailto:[EMAIL PROTECTED]]
Sent: Thursday, August 16, 2001 4:11 AM
To: [EMAIL PROTECTED]
Subject: Re: [castor-dev] Many-Many relationship in OQL


> In a Many-One relationship, I can do this:
> 
> select o from DetailClass o
> where o.parentObject.id = "...."
> 
> How can I do the similar thing in Many-many?
> 

No, OQL can't join two table through a many-table. There is some post
about this in the mailing list. There is a limited patch available for
castor 0.9.3.

Take a look at 
[castor-dev] Problem with bad SQL generation with many-to-many relation
posted 08/08/01.

Hope this can help,
  Florian Ramillien.

----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
        unsubscribe castor-dev

----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
        unsubscribe castor-dev

Reply via email to