PC Review


Reply
Thread Tools Rate Thread

composite key unmatched query

 
 
inungh
Guest
Posts: n/a
 
      27th Oct 2010
I would like to have a composite key unmatched query.
MS Access has user interface to create unmatched query, but only
support for one primary key. I just wonder are there any way to get
unmatched query for composite key.


Your information is great appreciated,


 
Reply With Quote
 
 
 
 
Bob Barrows
Guest
Posts: n/a
 
      27th Oct 2010
inungh wrote:
> I would like to have a composite key unmatched query.
> MS Access has user interface to create unmatched query, but only
> support for one primary key. I just wonder are there any way to get
> unmatched query for composite key.
>
>

Don't use the wizard. Create a new query in Design mode, select the
tables, create the joins, modify the joins so that an outer join is
created, pull one of the fields from the right side of the join into the
grid and enter "Is Null" into the criteria row. Pull the fields you need
to see from the table on the other side of the join into the grid and
run it.

Or skip all that: switch immediately to SQL View and write the query you
need:

SELECT t1.*
FROM TableWithAllData As t1
LEFT JOIN TableWithMissingDataAs t2
ON t1.keyfield1 = t2.keyfield1 AND ... AND t1.keyfieldN=t2.keyfieldN
WHERE t2.keyfield1 IS NULL

--
HTH,
Bob Barrows



 
Reply With Quote
Reply

Thread Tools
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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Unmatched Query DS Microsoft Access Queries 3 8th Jan 2008 10:14 PM
Changing a Unmatched query into a delete query yellowboy327 Microsoft Access Queries 0 13th Dec 2007 03:59 PM
Re: Unmatched query - help please. Smartin Microsoft Access Queries 2 18th Jan 2007 11:51 PM
Creating a Delete Query from an Unmatched Query =?Utf-8?B?aGdid2hpdGU=?= Microsoft Access Queries 3 15th May 2006 08:57 PM
Unmatched Query (hot to see unmatched data) J Haden Microsoft Access Queries 4 27th Jan 2004 06:50 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 03:28 PM.