UtterAccess.com
We have detected that you are using an unsupported web browser. We recommend you to upgrade your web browser to get the most from UtterAccess forums.
Why should and how can I upgrade?
X   Site Message
(Message will auto close in 2 seconds)

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> When Best To Use A Multi-value Field For A Beginner, Office 2007    
 
   
KathCobb
post Apr 10 2012, 07:55 AM
Post #1

UtterAccess Veteran
Posts: 453



good morning.
I am in the process of building my 1st database for an insurance agency. Ten agents and approximately 8,000 clients and growing. When I began the database design , it seemed easy enough as each client, although they had multiple policies, they only had one agent. Now I find out that One Client can have multiple agents, as well. Originally I had the input form 1 to be the Client Info and this is where I associated the client with an agent (combo box from my agent table). Then after saving the client info, the next Form to open would be the policy sale entry, carrying along with it the Client's name and the agents name already. after completing the sale info, on save the next form opens to enter commissions, again carrying along the client and agent--just FYI. Now, I am told that the client can be sold different policies by different agents. My 1st thought was just then associate the agent with the sale of the policy only. Would this be correct?
Why I am worried is because the main info that they wish to extract from this database is to be able to 1) look up the client and the policies when the client calls with a question. And 2.) to be able to sort the clients by agent in case of repeat visits. A normal report (or printable form?) that will be used often will be Agent A needs a list of all his clients in the County B. Since I haven't even gotten far enough to begin reports yet, ( I really am just a beginner) I would like to know if I associate agent only with sale, will I be able to get a print out like that without showing Mary Jones on the list 3 times for her 3 policies (Just once as a client)? It is okay, if Mary Jones showed up on the list for each agent she may have.
My second choice, was to have a multi value field on the client info form and I could select both agents there when the time comes. It is probably only 50 clients out of a thousand clients that have multiple agents. So Mrs. Jones probably already has two policies with Agent A but then she may be sold a third by Agent B. This would require the person inputting the sale, to open the Client Info form and choose the second agent then.
If anyone could advise on what the best way to do this would be, that would be great. I am getting a lot of pressure to get this database to a stage where I can begin entering info and they can use it to look up clients. All the bells and whistles can come later. They were using an unbelievably unwieldy spreadsheet that someone started deleting cells only then sorted so now none of the info matches up correctly across the columns. They have no way to access anything without going to the paper file cabinets.
Thank you for any advice you can offer.
Kathy
Go to the top of the page
 
+
mike60smart
post Apr 10 2012, 08:00 AM
Post #2

UtterAccess VIP
Posts: 9,990
From: Dunbar,Scotland



Hi Kath
It would help if you could upload a zipped copy of the Db so we can take a look at the structure
Go to the top of the page
 
+
GroverParkGeorge
post Apr 10 2012, 09:15 AM
Post #3

UA Admin
Posts: 22,346
From: Newcastle, WA



You have a many-to-many relationship. These relationships are implemented through a junction table which sits between the two related tables. Handling this properly will require removing the agentID from the client table and putting it into the new junction table. This is additionally complicated by the fact that policies are also related to the client and agent, not just the client. I do not think the relationship is actually just between client and agent, in fact. The relationship involves client, policy AND agent. After all, a client could have an auto policy with agent "A" and a second auto policy with agent "B". Not likely, I grant, but possible.
ere's a basic structure.
tblAgent
=======
AgentID PK
AgentFirstName
AgentLastName
(other attributes)
tblClient
=======
ClientID PK
ClientFirstName
ClientLastName
(other attributes)
tblClientPolicy
=========
ClientPolicyID PK
ClientID FK to client table
PolicyNumber
AgentID FK to agent table
(other attributes of the policy)
Orealize that refactoring this database is not going to be a small task, but you do need to make it conform to the actual business rules you have to support.
Go to the top of the page
 
+
Bob G
post Apr 10 2012, 09:24 AM
Post #4

UtterAccess VIP
Posts: 10,332
From: CT



Only because it is mentioned in the title of the thread.
The Evils of Lookup Fields in Tables
Go to the top of the page
 
+
pere_de_chipstic...
post Apr 10 2012, 09:24 AM
Post #5

UtterAccess Editor
Posts: 8,931
From: South coast, England



Hi Kathy
irstly it is vitally imortant that you get you database stucture correctly designed and properly normalised - this will make you future updates (the bells and whistles) a lot easier (and possible!) These references will point you in the right direction:

Most experienced developers woud advise you to steer clear of Multi Value Fields until at least you are fully aware of the implications of using them, and use a more standard junction table instead (As George has already posted!).
hth
Go to the top of the page
 
+
theDBguy
post Apr 10 2012, 10:15 AM
Post #6

Access Wiki and Forums Moderator
Posts: 57,831
From: SoCal, USA



Hi Kathy,
agree with all the comments so far. Avoid MVFs and try to implement the new structure that George offered. That is, associate the agent to the policy instead of the client. You can use queries to connect everything else together for your reports.
Just my 2 cents... 2cents.gif
Go to the top of the page
 
+
KathCobb
post Apr 11 2012, 07:52 AM
Post #7

UtterAccess Veteran
Posts: 453



Hello again. I have attached a copy of my database. I am a little embarrassed of it because it does have queries and information that were experiments in me trying to figure things out. Here's the thing. I actually started trying to teach myself access back in the summer of 2007 using Access 2003 to help out 2 friends in the insurance business. I got as far as my database is now. Then one of the agents moved and I abandoned the project. Now, the agent that stayed here has formed a bigger agency in the ensuing years and had been keeping his clients in a crazy spreadsheet. Someone deleted some cells, sorted the list and bamm, now the spreadsheet is useless. So I am back up at bat….using Access 2007 and having forgotten most everything I have learned and an urgency to get this done yesterday.
had asked about associating the sales with the agent and/or client. And a junction table was suggested. I believe I started it that way. And that is what I have with the policy table??
Oreally really really need help with normalization, making sure that I can sort the database to produce a list of all Agent A’s client by a specific county. And not end up getting Client Mary Jones 3 times because she has three policies with us. It is okay if Mary Jones has two agents and she ends up on both Agents lists—that is what we want to happen. Which was my question about the multi-value field.
For normalization purposes, I am stumped at the level of necessary normalization for the addresses. County wasn’t important before, but now it is the main focus. I plan to make that a look up table because Counties won’t change. Now I have the address in a table with the client info. Put I believe an address table is more appropriate. Yes, 2 clients may share the same address. (usually husband/wife) But I really don’t want to break out house number from the street and putting cities and zip code and in their own tables seems overwhelming to me. But I will be dealing with 8000 clients and growing so I don’t want a problem in the future.
The second question I have with normalizations is commission table. Right now the commissions are only be recorded as an FYI but eventually if I can get this working right, I’d like the agency to be able to count on it as a way to really process payments. Right now all that is done by hand. Each agent is paid an Advance at time of Sale and the A second amount called an Override and the a third amount is the residuals(also called renewals) that last 7 years or until cancel. I had all these things 1 table, then made a residuals table and then put it back in commission table. Which way would be the best way to go?
If you have any other tips or ideas on how to make this thing operational as fast as possible I would really really appreciate it. I figure I can design better forms and reports as the information is being inputted and utilized but the structure has to be right before that can happen.
ANY help would be so appreciated.
Thank you all!
Go to the top of the page
 
+
mike60smart
post Apr 11 2012, 11:08 AM
Post #8

UtterAccess VIP
Posts: 9,990
From: Dunbar,Scotland



Hi Kathy
I have only taken a quick glance at your Form Structures
You are going about this in the wrong way
A Client has Sales
1 Client can have Many Sales
You are basing your Form on a query that incl;udes BOTH Client & Sales
What you actually need is:-
The Main Form Based on the Client
This Main Form would then be linked to a Subform based on Sales
This structure allows you to see the Parent Record of the CLIENT
with the Subform automatically displaying the CHILDREN Records (Many Sales)
Go to the top of the page
 
+
KathCobb
post Apr 11 2012, 12:38 PM
Post #9

UtterAccess Veteran
Posts: 453



I have a whole bunch of forms, some for practice, some I thought were ok. Do you know which form you looked at?
Thank you for looking it over.
Kathy
Go to the top of the page
 
+
mike60smart
post Apr 11 2012, 03:32 PM
Post #10

UtterAccess VIP
Posts: 9,990
From: Dunbar,Scotland



Hi Kathy
The forms are the ones which run from your Main Switchboard
Go to the top of the page
 
+

Thank you for your support! Reply to this topicStart new topic

Jump To Forum:
 



RSS Search  ·  Go to Top  ·  Lo-Fi Version Time is now: 2nd September 2014 - 01:42 AM