Results 1 to 7 of 7
  1. #1
    Join Date
    Jan 2008
    Posts
    8

    Unanswered: The error many to many ralationship

    I have built the junction talbe "Work"but the error occoures "Relationships Must Be on Same Number of Fields".I like to build many to many relationship for 3 tables: Personel,Work and Project.One person can work on many project, and one project can have many persons working on it.I have one to many relationship from Project Table to Work table, but cannot build relationship from Personel to Work and meet te error above.

  2. #2
    Join Date
    Jul 2003
    Location
    Amsterdam, Nederland
    Posts
    450
    Can you attach a printscreen of your tables.

    Not sure about your order of linking
    Greetz Marvels -^.^-
    Developments : VB4 Through .Net; Basic; DOS ; CNC ; Sinclair
    Databases : SQL Server Through 2005; Access 3 Through 2003 ; Oracle 8 & 9.i ;
    OS : Win 3.11 Through XP ; NortonComander ; DOS

  3. #3
    Join Date
    Sep 2007
    Location
    Global Village
    Posts
    185
    For building many-to-many relationship between two tables in MS-Access you need a third table which I call it connector table and make many-to-one relationship between each table and connector table; finally you have a many-to-many relationship between your tables.
    Cheers

  4. #4
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Make sure the fields you are relating together are the same data type. You cannot have a relationship between a text field and a numeric field for example. You also cannot create a relationship between a long integer and a double -- even though they are both numeric.

    You must also create your relationships on the same number of fields... you cannot have a relationship between two fields on one side and three on the other.

    That is what the message you are receiving is complaining about.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  5. #5
    Join Date
    Jan 2008
    Posts
    8
    Thanks a lot StarTrekker,Aran1 and Marvels.I solved it and found that error: long integer and double.

  6. #6
    Join Date
    Jan 2008
    Posts
    8
    Hi all,
    I am building the a form"WORKand PERSONEL" consisting Project ID, Project Name, and personel who takes apart on it.So I have a List Box including Name and ID. How can I add Name and ID into that form?

  7. #7
    Join Date
    Feb 2004
    Location
    One Flump in One Place
    Posts
    14,912
    Guys - please respond to the last question here:
    http://www.dbforums.com/showthread.php?t=1627588

Posting Permissions

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