General information
Category:
Coding, syntax & commands
Mark, thaks for the reply. Sounds like what I am lookinf for and I'll give it a try.
Gerard
>>I need to run a SQL statement which selects all records from File1 ,but excludes any records where there is a link to a second file based on one of the fields:
>>
>>In simple terms:
>>
>>e.g. File 1: F1_code,F1_Name
>> File 2: F2_Code
>>
>>
>>Select * from File1 where (F1_code does not already exist in File2)
>>
>>Is there a way of doing this in SQL. I tried using a where Seek(..) = .F. but know from past experience that its a bit dicey using functions inside a SQL statement
>>
>>Regards,
>>
>>Gerard
>
>HI,
>
>SELECT * FROM File1 WHERE F1_code NOT IN (SELECT DISTINCT F2_Code FROM File2)
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only