Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Relating 2 tables to one

Status
Not open for further replies.

nayfeh

Programmer
Mar 13, 2002
163
CA
I have 2 customer master tables (A and B) that I want to relate to a single transactions table. The customer number relates the transactions table to both customer tables. When entering transactions, the user must enter a customer number from either of these tables. How can I allow the user to chose a customer number from table 1 OR table 2. i.e. if a customer number 1 is not in table A, it must be in table B for a new transaction to be allowed.

I think I have my relationships set up incorrectly, because only customers that are in BOTH tables are allowed to be entered in the transactions table. (By the way, there are a few duplicated entries in both Customer master tables)

Thanks in advance for your help.
 
I think what you need to do us UNION the two Customer Number fields
( Create a UNION query between tblCustomerA and tblCustomerB )

Then use that to supply available Customer Numbers to the Transaction table


G LS
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top