ofbiz-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Hugo Palma <hugo.m.pa...@gmail.com>
Subject Re: Creating a many-to-many relation
Date Thu, 01 Jul 2010 09:54:53 GMT
Thanks Nicolas and David. Got it working.

Cheers,
Hugo

On Wed, Jun 30, 2010 at 17:24, David E Jones <dejc@me.com> wrote:

>
> I think what Nicolas is trying to say is that in a physical model for a
> relational database there is no such thing as a many-to-many relationship
> between tables, so you need a "join" table to implement that conceptual
> model.
>
> In OFBiz you'll see a lot of these sorts of entities with a suffix of
> "Assoc" or "Appl" or sometimes other or no suffix, but you can find examples
> with those suffixes.
>
> -David
>
>
> On Jun 30, 2010, at 10:11 AM, Nicolas Malin wrote:
>
> > Hello Hugo,
> >
> > You just create an associate class ABAssoc that contains only A pk and B
> pk
> >
> > Nicolas
> >
> > Le 30/06/2010 17:37, Hugo Palma a écrit :
> >> Hi,
> >> i would like to create a many-to-many relation between to entities but i
> >> can't find any information or example on how to do this.
> >>
> >> For example, let's say i have the following entities:
> >>
> >> <entity entity-name="A">
> >> <field name="ida" type="id"/>
> >> <prim-key field="ida"/>
> >> </entity>
> >>
> >> <entity entity-name="B">
> >> <field name="idb" type="id"/>
> >> <prim-key field="idb"/>
> >> </entity>
> >>
> >> How can i model a many-to-many relationship between these two entities ?
> >>
> >> Thanks in advance,
> >> Hugo
> >>
> >>
> >
> >
> > --
> > Nicolas MALIN
> > Consultant
> > Tél : 06.17.66.40.06
> > Site projet : http://www.neogia.org/
> > -------
> > Société LibrenBerry
> > Tél : 02.48.02.56.12
> > Site : http://www.librenberry.net/
> >
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message