Below are three tables representing a simplified version of what I'm
trying to do. In each table, its "UniqueID" is an AutoNumber field, and
is the table's primary key.
I would like to be able to use one phone table that can be related to
both tblModel and tblVendor. tblModel and tblVendor contain dissimilar
fields. The ForeignKey in tblPhone would be the UniqueID of a row in
either tblModel or tblVendor.
Furthermore, each of these relationships can be one-to-many, the "many"
being on the tblPhone end.
When I attempt to establish these relationships, Access will not allow
it. I can kind of understand why this may be...for example, tblModel
could have a UniqueID 7, and so could tblVendor.
I would like to be able to use a single phone table instead of one each
for tblModel and tblVendor for a few reasons:
- I don't want to have to define two tables, especially if fields are
added later.
- If I want to run a query for all phone numbers in the database, that
query would me much simpler if it had to be run against one table only.
- There may be a couple more tables that need to have a relationship
with tblPhone, so if I could just add such a table and establish the
relationship, it would be quick and easy.
Perhaps what I'm trying to do can't be done. However, if someone
has an alternative that gives me the same end result, I'd be
interested in hearing it. I really don't want to have to set up a
separate phone table for each table that needs a phone table
relationship.
tblModel
---------
UniqueID
ModelName
Time
Date
tblVendor
---------
UniqueID
Address
Contact
tblPhone
-----------
UniqueID
ForeignKey
PhoneNumber 2 1216
gcloise,
<gc*****@hotmail.comwrote in message
news:11**********************@q2g2000cwa.googlegro ups.com...
Below are three tables representing a simplified version of what I'm
trying to do. In each table, its "UniqueID" is an AutoNumber field, and
is the table's primary key.
I would like to be able to use one phone table that can be related to
both tblModel and tblVendor. tblModel and tblVendor contain dissimilar
fields. The ForeignKey in tblPhone would be the UniqueID of a row in
either tblModel or tblVendor.
Furthermore, each of these relationships can be one-to-many, the "many"
being on the tblPhone end.
When I attempt to establish these relationships, Access will not allow
it. I can kind of understand why this may be...for example, tblModel
could have a UniqueID 7, and so could tblVendor.
I would like to be able to use a single phone table instead of one each
for tblModel and tblVendor for a few reasons:
- I don't want to have to define two tables, especially if fields are
added later.
- If I want to run a query for all phone numbers in the database, that
query would me much simpler if it had to be run against one table only.
- There may be a couple more tables that need to have a relationship
with tblPhone, so if I could just add such a table and establish the
relationship, it would be quick and easy.
Perhaps what I'm trying to do can't be done. However, if someone
has an alternative that gives me the same end result, I'd be
interested in hearing it. I really don't want to have to set up a
separate phone table for each table that needs a phone table
relationship.
tblModel
---------
UniqueID
ModelName
Time
Date
tblVendor
---------
UniqueID
Address
Contact
tblPhone
-----------
UniqueID
ForeignKey
PhoneNumber
gcloise,
You could add two foreign key columns to the tblPhone table, ModelID and
VendorID. If a phone number is associated with a Model and a Vendor, then
both columns would be populated. If not, only one column would be populated
and the other would be null.
-- Bill
<gc*****@hotmail.comwrote in message
news:11**********************@q2g2000cwa.googlegro ups.com...
Below are three tables representing a simplified version of what I'm
trying to do. In each table, its "UniqueID" is an AutoNumber field, and
is the table's primary key.
I would like to be able to use one phone table that can be related to
both tblModel and tblVendor. tblModel and tblVendor contain dissimilar
fields. The ForeignKey in tblPhone would be the UniqueID of a row in
either tblModel or tblVendor.
Furthermore, each of these relationships can be one-to-many, the "many"
being on the tblPhone end.
When I attempt to establish these relationships, Access will not allow
it. I can kind of understand why this may be...for example, tblModel
could have a UniqueID 7, and so could tblVendor.
I would like to be able to use a single phone table instead of one each
for tblModel and tblVendor for a few reasons:
- I don't want to have to define two tables, especially if fields are
added later.
- If I want to run a query for all phone numbers in the database, that
query would me much simpler if it had to be run against one table only.
- There may be a couple more tables that need to have a relationship
with tblPhone, so if I could just add such a table and establish the
relationship, it would be quick and easy.
Perhaps what I'm trying to do can't be done. However, if someone
has an alternative that gives me the same end result, I'd be
interested in hearing it. I really don't want to have to set up a
separate phone table for each table that needs a phone table
relationship.
tblModel
---------
UniqueID
ModelName
Time
Date
tblVendor
---------
UniqueID
Address
Contact
tblPhone
-----------
UniqueID
ForeignKey
PhoneNumber This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Jeff Lanfield |
last post by:
Suppose I have users that can belong to organizations. Organizations
are arranged in a tree. Each organization has only one parent
organization but a user maybe a member of multiple organizations....
|
by: Todd D. Levy |
last post by:
I have a primary table (containing basic contact information) and a
number of subsidiary tables (containing various additional information)
for employees.
Most of the subsidiary tables have a...
|
by: Marco Simone |
last post by:
Hi,
I have 4 tables, tblCompany, tblA, tblB and tblC.
tblA, tblB and tblC contain same type of data, they should be in one table,
but since there are many fields, I split it into 3 tables.
Each...
|
by: Mindy |
last post by:
Hey,
I want to create links between my two tables. The primary keys of these
two tables are character variables, with length =11. I followed exactly
the instruction of Dummuy Book for ACCESS...
|
by: shawnews |
last post by:
Ok...I'll first describe briefly what I've done.
Working from a paper form with over 200 fields - broken into 10 areas, I
created a database with 10 tables. I then created a form using those 10...
| |
by: adham |
last post by:
Hey there,
Im not even sure if im using the terminology correctly. Anyway heres
my questions. I have a three tables. The main table has two ID fields.
A website id, which is the primary key in...
|
by: RobertJohn |
last post by:
Hi all
I am using Access 2007 to start a small home library application, and so far it has two tables.
1. Books, with fields Book_ID (Primary Key) and Title, and
2. Authors, with fields...
|
by: PW |
last post by:
Hi,
I set up a relationship between two tables with the itineraryid fields
in both tables:
tblDailyItinerary
tblDailyMeals
I have a form that writes a record to tblDailyItinerary that...
|
by: NicoleCartrette |
last post by:
Going back to school is easier said than done..
This was posted to an older thread earlier but I don't think it got any attention. Your help is appreciated
Professor requires we create a...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
| |
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...
| |