Microsoft Access Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsDatabaseMicrosoft Access Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread ASP Free Forums Sponsor:
  #1  
Old March 3rd, 2004, 01:36 PM
lambda75 lambda75 is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Dec 2003
Location: Orlando, fl
Posts: 8 lambda75 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Redundancy

I have 3 tables, A, B, C. In table A I have an EmpID which is the same as PID in B and RID in C.

What would I have to do, so I could run a query to retreive all EmpID except the ones that match the PID in table B and RID in table C

Thanks,

Jose

Reply With Quote
  #2  
Old March 3rd, 2004, 05:30 PM
Stev Stev is offline
Contributing User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Oct 2003
Location: Queensland, Australia
Posts: 256 Stev User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 58 m 53 sec
Reputation Power: 6
Drop tables A, B, and C into the query builder and make joins between 'A and B' and 'A and C'. Table A should be the "One" side of the One to Many joins.

Select the EmpID, PID and RID fields and any others you may require.

In the criteria for the PID and RID fields put "Is Null"

Go to datasheet view and you should see the records you require.

The SQL for the query is as follows.

SELECT Personell.PID, Employees.EmpID, Residents.RID
FROM Residents RIGHT JOIN (Personell RIGHT JOIN Employees ON Personell.PID = Employees.EmpID) ON Residents.RID = Employees.EmpID
WHERE (((Personell.PID) Is Null) AND ((Residents.RID) Is Null));

Reply With Quote
Reply

Viewing: ASP Free ForumsDatabaseMicrosoft Access Help > Redundancy


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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 On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway
Stay green...Green IT