Ask Experts Questions for FREE Help !
Ask
    jobie79's Avatar
    jobie79 Posts: 6, Reputation: 1
    New Member
     
    #1

    Mar 29, 2011, 07:34 PM
    Issues creating a one to many relationtionship in Access 2010
    I have two tables (Clients / Quotes) and I want to create a report for each client displaying a list of quotes that has been sent to them. The 'Quotes Form' can have up to 6 clients being priced the same project with a 7th client field for the winning client.

    So the relationship view looks like this;

    Company Name -> Client Q1, Client Q2, Client Q3, Client Q4, Client Q5, Clent Q6, Project Won By.

    The problem I have is that access seems to want the company name in each (a logical AND function) however I want access to check the seven coloums in each record and run as a logical OR function. So if Bill's Construction is in Q2 it will still show up under Bill's Construction in the report and under Fred's who was entered into Q1.

    Any Company Name can be selected and entered into any of the Client Q1 - Q6 or Project Won By and in any order.

    Grateful for any ideas and assistance.
    ScottGem's Avatar
    ScottGem Posts: 64,966, Reputation: 6056
    Computer Expert and Renaissance Man
     
    #2

    Mar 31, 2011, 03:43 PM

    It looks like your database is not normalized properly. Having fields like Client1, client2, etc,constitutes a repeating group which violates normalization rules.

    What I don't understand is the relationship here. I could understand if you were accepting bids from Client1, 2 etc. But that doesn't appear to be what you are saying. So, if you can explain how your business operates a bit clearer I can suggest how to make this work.
    jobie79's Avatar
    jobie79 Posts: 6, Reputation: 1
    New Member
     
    #3

    Mar 31, 2011, 05:33 PM
    Comment on ScottGem's post
    Scott
    Apologies. Hopefully this will clear it up a bit.

    We are a subcontractor to a number of builders and the projects we price can be quoted to any number of them.
    For example; Clients 1, 2, 6,8 & 10 can all be pricing project 1.
    Clients 2,6 & 7 can all be pricing project 2. so on and so forth.
    What I need to do is to be able to create a report showing that I have priced Project 1 to client 1. Projects 1 & 2 to client 2, same for client 6, and project 2 to client 7.

    In summary we price any one project to multiple clients. Any client can receive quotes for multiple projects.
    Need to produce a report per client showing which projects have been quoted to that client.

    Thanks for your help.
    ScottGem's Avatar
    ScottGem Posts: 64,966, Reputation: 6056
    Computer Expert and Renaissance Man
     
    #4

    Mar 31, 2011, 06:25 PM

    This still isn't making sense. In my world a contractor can send a job out for bid to multiple "clients". But I don't understand quoting the same project to multiple clients.

    But I think you have a many to many relationship here. One client can be associated with multiple projects and one project can be associated with multiple clients. So you need three tables. A projects table and a clients table and a junction table to manage the many to many relation.

    The junction table will have a structure like:

    ProjectID
    ClientID

    You will have a record for each project offered each client.
    jobie79's Avatar
    jobie79 Posts: 6, Reputation: 1
    New Member
     
    #5

    Apr 4, 2011, 08:41 PM
    Comment on ScottGem's post
    Scott
    Hope this helps

    jobie79's Avatar
    jobie79 Posts: 6, Reputation: 1
    New Member
     
    #6

    Apr 4, 2011, 09:13 PM
    Comment on ScottGem's post
    [img=http://img825.imageshack.us/img825/5862/30237950.th.jpg]
    ScottGem's Avatar
    ScottGem Posts: 64,966, Reputation: 6056
    Computer Expert and Renaissance Man
     
    #7

    Apr 5, 2011, 03:26 AM

    But that illustrates what I have been saying. You as the subcontractor get a job from a builder. You then go out and ask for bids from other contractors. Some bids may be duplications, others may even be a sole bid. For example, you may ask for bids from 4 drywall installers, 3 electricians, 5 plumbers and one cable installer. So you have a Project table that defines the whole project, a Jobs table that defines each part of the Project (i.e, drywall, electrical, etc.), a Builders table that lists the firms you send out bids to, and a Bids table to list each bid sent; what Job it was for, who it was sent to and the results.

    That's fairly standard.
    jobie79's Avatar
    jobie79 Posts: 6, Reputation: 1
    New Member
     
    #8

    Apr 5, 2011, 01:36 PM
    [IMG][img=http://img825.imageshack.us/img825/5862/30237950.th.jpg][/IMG]
    jobie79's Avatar
    jobie79 Posts: 6, Reputation: 1
    New Member
     
    #9

    Apr 7, 2011, 05:53 PM
    Comment on ScottGem's post
    Scott
    Could you have a look at the following and let me know if I have this right? I can't get my head around this. :(

    http://img683.imageshack.us/i/relationships.jpg/
    ScottGem's Avatar
    ScottGem Posts: 64,966, Reputation: 6056
    Computer Expert and Renaissance Man
     
    #10

    Apr 7, 2011, 06:03 PM

    Have you read any articles on Normalization? Because what you have set up is not normalized. Your Client List is the only thing that is correct, except that has some issues too. It is not good practice to have spaces in object names.

    Go back to post #7 and see the structure I suggested there. And read up on normalization.

Not your question? Ask your question View similar questions

 

Question Tools Search this Question
Search this Question:

Advanced Search

Add your answer here.


Check out some similar questions!

Need help creating a relationship in Access 2010 [ 4 Answers ]

Hi all, I'm trying to build an access db (I don't know access very well) to keep track of my rechargeable batteries (geeky I know). Here are my tables: BatteryType: Just contains the different types of batteries available Inventory: contains batterytype, serial number, purchase date, etc...

Creating a report/query in Access [ 16 Answers ]

I have an acess Database that my boss set up for me. I enter employee names what time they sign in sign out for lunch sign back in and sign out for the day... How do I make a report/or query that can give me a monthly average for each person?

Creating simple queries in Access 2007 [ 12 Answers ]

Hello there. I'm a student in Information Technology Management and am working on an assignment for Access 2007. I ran into some issues with creating my queries and cannot seem to get the right results. Can anyone help?

MS Access 2003 Creating a form with input of ranges of data [ 4 Answers ]

Dear Scott, I tried attaching the front and back end of my database and I got the following message, "Your submission could not be processed because a security token was missing. If this occurred unexpectedly, please inform the administrator and describe the action you performed before you...

Creating a relationship in Access [ 1 Answers ]

I am trying to link Customer Contact Information to numerous orders they have placed. I have created the relationship, but not sure on how to creat the form view to correspond the two relationships. Any insight would be very helpful.


View more questions Search