I have two tables. One is 2nd Level AFDA and other InterCompany
2nd Level AFDA has 5 fields and Intercompany has two.
Both have SAPStrNo field comman. I want to join thes tables and ignore all the SAPStrNo records found in InterCompany. Following SQL query is not working.
I have 1206 records in 2nd Level AFDA and 22 records in Intercompany. Following Query generate 26531 records which definetly wrong because I expect less than 1206 records due to this query
SELECT [2nd Level AFDA].SAPStrNo, [2nd Level AFDA].StoreNo, [2nd Level AFDA].AccType, [2nd Level AFDA].Sortype, [2nd Level AFDA].Banner
FROM [2nd Level AFDA] where [2nd Level AFDA].SAPStrNo <> InterCompany.SAPStrNo;