A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Database Design
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

How do I link one person to another in the same table?



 
 
Thread Tools Display Modes
  #1  
Old November 24th, 2009, 10:19 PM posted to microsoft.public.access.tablesdbdesign
E289
external usenet poster
 
Posts: 1
Default How do I link one person to another in the same table?

I have a table of Contacts. Some of my contacts know other contacts, and I
would like to indicate that in their record. However, for Data Type, I
cannot create a drop down list of contacts from within the table to choose
from.

Any idea how to to this? Or, if this is not possible, can you suggest
another way to indicate "who knows whom"?
  #2  
Old November 24th, 2009, 10:36 PM posted to microsoft.public.access.tablesdbdesign
Steve[_77_]
external usenet poster
 
Posts: 1,017
Default How do I link one person to another in the same table?

Your contact table ought to look like:
TblContact
ContactID
FirstName
LastName
etc

Then you need am acquaintenances table:
TblAcquaintenance
AcquaintenanceID
ContactID (identifies a Contact)
AcquaintedContactID (Identifies a contact ContactID knows)

If ContactID 21 knows ContactIDs 1,7, 32 and 47, TblAcquaintenance would
lool like:
1 21 1
2 21 7
3 21 32
4 21 47

Steve




"E289" wrote in message
...
I have a table of Contacts. Some of my contacts know other contacts, and I
would like to indicate that in their record. However, for Data Type, I
cannot create a drop down list of contacts from within the table to choose
from.

Any idea how to to this? Or, if this is not possible, can you suggest
another way to indicate "who knows whom"?



  #3  
Old November 24th, 2009, 10:53 PM posted to microsoft.public.access.tablesdbdesign
Gina Whipp
external usenet poster
 
Posts: 3,500
Default How do I link one person to another in the same table?

E289,

Try creating using a Query based on that table and use the Query as the
RowSource in the Combo Box on your form.

--
Gina Whipp

"I feel I have been denied critical, need to know, information!" - Tremors
II

http://www.regina-whipp.com/index_files/TipList.htm

"E289" wrote in message
...
I have a table of Contacts. Some of my contacts know other contacts, and I
would like to indicate that in their record. However, for Data Type, I
cannot create a drop down list of contacts from within the table to choose
from.

Any idea how to to this? Or, if this is not possible, can you suggest
another way to indicate "who knows whom"?



  #4  
Old November 24th, 2009, 11:05 PM posted to microsoft.public.access.tablesdbdesign
KARL DEWEY
external usenet poster
 
Posts: 10,767
Default How do I link one person to another in the same table?

Use an Autonumber field as primary key field in the Contacts table.

If the known contacts are only one way like employes to supervisor add a
number - long integer field also as Supervisor. Then in the relations
window add the Contacts table twice (Access will add a sufix, Contacts_1 to
the second instance). Create a one-to-many from first table primary key
field to the Supervisor field of the second (many employes can have the same
boss).

If the contacts are multiple in both directions then you need a junction
table, JCTContact with two number - long integer fields. Name them something
like Cont1 and Cont2. The in the relations window add the Contacts table
twice and the junction table once. Create a one-to-many from first table
primary key field to the Cont1 field of the junction table. Repeat from
second Contacts to Cont2.

Use form/subform for Contact to Contact. The subform to have combo to
select associated contact for person shown in the main. Use scrolling to
locate person in main.

--
Build a little, test a little.


"E289" wrote:

I have a table of Contacts. Some of my contacts know other contacts, and I
would like to indicate that in their record. However, for Data Type, I
cannot create a drop down list of contacts from within the table to choose
from.

Any idea how to to this? Or, if this is not possible, can you suggest
another way to indicate "who knows whom"?

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 08:07 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.