Results 1 to 10 of 10
  1. #1
    Exwarrior187 is offline Novice
    Windows XP Access 2003
    Join Date
    Jan 2011
    Posts
    13

    Relationships Question(s)

    This Forum has been great since I joined recently!



    That being said I come back to the well of knowledge for another drink.

    I have created a DB that has two separate tables that were currently working in. One for Existing Customers named 'North Florida' and another for Potential Customers named 'North Florida Prospects'.

    These two tables are identical with the exception of some data types and validations. We find ourselves in need of keeping track of more information on these customers entered into both of these tables, ie the creation of two new tables 'Follow Up' and 'Revenue'. So Relationships and Database Normalization comes to mind, two subjects that I'm vaguely familiar with.

    I've been trying to figure it out through a series of web searches and do-it-yourself attempts but I'm worried that I'm on the brink of bringing my entire house of cards down. Attached is a picture of the Relationships I've created and the way it would seem to work to me thus far.

    Ultimately what I'm after is that when we get a Qualified Sales Lead from my first two original tables, I want it to be created in my two new tables with the 5-6 data points replicating from the Master tables 'North Florida' and 'North Florida Prospects'.

    Many thanks in advance, I'm just looking to get on the right track here.

  2. #2
    TheShabz is offline Court Jester
    Windows XP Access 2003
    Join Date
    Feb 2010
    Posts
    1,368
    Woah. Too many joins! Two tables should only be joined by one field. Before you start messing with it, I really recommend reading up on Normalization. As you described them, The North Florida table and the Prospects table can be merged into one table, with an extra field named isProspect that holds a yes/no value. Further, this new table should then be broken up. For example. "Customer Type" should have its own table where you would have a foreign key relating to it. Products should have their own table. Calls should have their own table.

    Further, I'd remove all spaces and special characters from the field names as it can make things difficult for you later on.

    "Normalization" and "relational database" are two terms I think you would benefit from reading up on.

  3. #3
    Exwarrior187 is offline Novice
    Windows XP Access 2003
    Join Date
    Jan 2011
    Posts
    13
    Thanks for the reply! I did a little digging and found an article that was written in verbage that I understood.

    http://www.databasejournal.com/sqlet...malization.htm

    Now to put it into use! The Database Analyzer wants to take my existing tables apart and place it in 10 tables, to me that seems like it's going to be a sizeable task to run queries against.

  4. #4
    TheShabz is offline Court Jester
    Windows XP Access 2003
    Join Date
    Feb 2010
    Posts
    1,368
    As far as the number of tables, it really all depends on the functionality you are looking for. the Database Analyzer isn't the be-all end-all of normalization. Give it a shot on your own and post back your Relationship Window and we can keep adjusting until we get to where it needs to be.

  5. #5
    Exwarrior187 is offline Novice
    Windows XP Access 2003
    Join Date
    Jan 2011
    Posts
    13
    I'll be doing that believe me. First I need to take your first piece of advice and combine those two tables once I can get them to myself, which could take a day or two. Then once I've gotten them combined and identified as Customer/Prospect I'll start looking at how to best carve up the data.

  6. #6
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,737
    Here is a video on normalization.
    Hope it helps
    http://www.youtube.com/watch?v=uO80f...eature=related

  7. #7
    Exwarrior187 is offline Novice
    Windows XP Access 2003
    Join Date
    Jan 2011
    Posts
    13
    Ok TheShabz:

    I've combined both tables and Identified the records as Prospects and Non-Prospects.

    Which method should I persue in order to make sure that when we label a record as having sales that 3-4 fields are duplicated into a table I want to use to hold the Sales data?

    Many thanks once again.

  8. #8
    TheShabz is offline Court Jester
    Windows XP Access 2003
    Join Date
    Feb 2010
    Posts
    1,368
    This is where Forms and VBA come in to play. upon entering in sales information onto the form, with VBA you can write queries that will take the form information and update whatever tables you wish.

  9. #9
    Exwarrior187 is offline Novice
    Windows XP Access 2003
    Join Date
    Jan 2011
    Posts
    13
    Shabz:

    I have a button on our form with an OnClick event that runs a series of validations for the information stored in the form. What I'm missing is another Sub that would copy my 4 fields from the North Florida table into the Revenue table. They are named identically and share a relationship on the ID field.

  10. #10
    Exwarrior187 is offline Novice
    Windows XP Access 2003
    Join Date
    Jan 2011
    Posts
    13
    I was able to find the code linked below and tweaked it to my needs (changed table names etc.) Thanks for the advice all!

    http://bytes.com/topic/access/answer...m-fields-table

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Relationships
    By bopsgtir in forum Database Design
    Replies: 1
    Last Post: 01-10-2011, 12:44 PM
  2. Relationships again
    By BarbT in forum Access
    Replies: 2
    Last Post: 11-09-2010, 04:12 AM
  3. Too Many Relationships
    By MikeT in forum Database Design
    Replies: 4
    Last Post: 08-25-2010, 07:23 PM
  4. Another relationships question
    By canfish in forum Database Design
    Replies: 0
    Last Post: 07-28-2010, 02:23 PM
  5. question about relationships
    By grad2009 in forum Access
    Replies: 3
    Last Post: 02-16-2010, 06:12 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums