Comboboxes or Conections for Look up Tables and Data Tables

T

TravelingHT

Dear All:

I have a question. Reading about lookup tables, (e.g. tax rates for
different states) should I connect these lookup tables to my Data tables
(e.g. Customer Line Item Invoice Table) in my Relationship window or should
I just created a combobox with a record source being the tax rate table and
have no relationship defined in my "Relationship" window?

What is the difference between these two aproaches and what are the
advantages.

Thanks in advance.

Traveling Tech
 
C

Clifford Bass

Hello,

You definitely create the relationships. This will make sure your
table only contains valid data such as real state codes. If you do not,
someone could enter invalid codes. The combo box is a convenience for the
user. Use it if it helps the user. Don't use it if it is a hinderance.

My $0.02 worth,

Clifford Bass
 
T

TravelingHT

Dear Clifford:

So I hear the info about the customer. I will take that onboard.

Thanks for the response, to help me I need the why of it. Why if I am using
a combobox to create the list of choices and that list of choices has a limit
to list property. Then I am OK with just a combobox, and no link between the
tables.?

Under what circumstances will the above senario cause me a problem?

Is what I am asking just not that improtant, is there realy no big difference?

Yours truly.

Traveling Tech.
 
C

Clifford Bass

Hi Traveling Tech,

The difference is that with the relationships defined, you are
protecting the integrity of the data regardless of where it comes from. (Of
course, someone could still enter a wrong, but valid value.) If the only way
that anyone can get to the data is through your form, then it would work.
But there is no way to prevent someone from getting directly to the table;
they could link to it from another Access database or any number of other
ways such as ODBC or OLEDB. Plus, suppose down the road you want to create
an import function because you are getting data from somewhere else. Do you
want to trust that their data is all good? I would not. I would want an
error to occur if there was an invalid value.

Also, if you create the referential integrity and you find you need to
change a value in the code table, you can set it to cascade the change to any
child tables. For example when Canada changed the abbreviation for Quebec
from PQ to QC. And you can set it to prevent deletion of the parent records
when children exist so that someone could not delete an NY / New York entry
when it is in use elsewhere. Good database design includes the creation of
the referential integrity contstraints.

Hope this helps,

Clifford Bass
 
T

TravelingHT

Dear Clifford:

A lot of good information. I am building this DB for my self, my own
business. I am not aiming to use this for anyone else. I am not at the level
to understand what OLEBD or ODBC. I have become comfortable with two
different ways to reach the same goal and now looking at why there are two
different ways.

So you have helped me understand how it can affect referential integrity.

Thanks for your help I will keep learning.

Traveling Tech
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top