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!

append and delete query showing different results

Status
Not open for further replies.

ali32uk

Technical User
Mar 31, 2011
22
GB
Hi All

this is really confusing and me and cant figure the reason..

I have 2 queries - an append query and a delete query, they are exactly the same other than the type (append/delete) I even copied the append query and just changed the type once copied...

So my question is why are they delivering different results, the delete query returns 130K less records....

SQL - Append
INSERT INTO TBLSystemImportFinal ( RS, MPN ) IN 'D:\MatchedFinal.accdb'
SELECT TBLSystemImportCross.RS, TBLSystemImportCross.MPN
FROM TBLRSOfferCross INNER JOIN TBLSystemImportCross ON TBLRSOfferCross.CrossRS = TBLSystemImportCross.Cross
WHERE (((TBLSystemImportCross.RS) Is Not Null));

SQL - Delete
DELETE TBLSystemImportCross.RS, TBLSystemImportCross.MPN
FROM TBLSystemImportCross
WHERE (((TBLSystemImportCross.RS) Is Not Null));

Your help would be much appreciated!

Ali
 
With a DELETE query, you DELETE RECORDS NOT Fields.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top