Results 1 to 4 of 4

Thread: one-to-many

  1. #1
    Join Date
    Dec 2004
    Posts
    2

    Smile one-to-many

    Dear All,

    I would greatly appreciate if you can support me in enrity relationship issue.

    The is a one-to-many relationship between EntityA (PK:GUID) and EntityB (PK:GUID, FK: EntityAGUID) . Example, one "Entity" can have multiple "Portfolios". However, i have three types of type Entitiey A which need to be in seperate tables because each has it's own properties. Example,
    EntityA can be a Client, a Company, or a Fund

    Client Company Fund
    | | |
    | | |
    |_______ Portfolio _____|

    I am looking to have the same PK for the three tables "Client / Company / Fund " so that there will be no conflict in the "Portfolio" FK.

    Please advise for the best ERD structure.
    Greatly appreciated

  2. #2
    Join Date
    Apr 2002
    Location
    Toronto, Canada
    Posts
    20,002
    entitysupertype --- 1-m --- portfolio
    | | |
    | | +-- 1-1 --- clientsubtype
    | +-- 1-1 --- companysubtype
    +-- 1-1 --- fundsubtype
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL

  3. #3
    Join Date
    Dec 2004
    Posts
    2

    Thanks

    Thanks for your reply, it is what i am looking for

  4. #4
    Join Date
    Dec 2004
    Posts
    54

    WhoooOOOoaaAAA

    Hi Mr Aloha,
    Listen....you're mixing Apples and Oranges as we say in the data modeling word.

    If you're telling me A Client, A Comany and a Fund are three of the same type of thing, you didn't watch Sesame Street growing up.

    Looooook - A 'party' is a person or organization
    A fund is an account to group holdings or transactions under

    I smell something fishy here....

    Vmuisc

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •