Subject | Outer Joins |
---|---|
Author | Tim Ledgerwood |
Post date | 2003-11-13T08:21:29Z |
Hi all,
I know that this is a simple question, and that I should know the answer
... but I don't. *blush*
Given two tables, how do I write a select that will show me all the records
that are in Table1 but NOT in Table2?
CREATE TABLE TABLE1
(
RECORDNO INTEGER NOT NULL,
SEQUENCENUMBER INTEGER,
PRIMARY KEY(RECORDNO)
);
CREATE TABLE TABLE2
(
RECORDNO INTEGER NOT NULL,
SEQUENCENUMBER INTEGER,
PRIMARY KEY(RECORDNO)
);
In this example, assume that I want to find all of the records in Table1
where there is no matching record in Table2.
Thanks in advance,
Tim
[Non-text portions of this message have been removed]
I know that this is a simple question, and that I should know the answer
... but I don't. *blush*
Given two tables, how do I write a select that will show me all the records
that are in Table1 but NOT in Table2?
CREATE TABLE TABLE1
(
RECORDNO INTEGER NOT NULL,
SEQUENCENUMBER INTEGER,
PRIMARY KEY(RECORDNO)
);
CREATE TABLE TABLE2
(
RECORDNO INTEGER NOT NULL,
SEQUENCENUMBER INTEGER,
PRIMARY KEY(RECORDNO)
);
In this example, assume that I want to find all of the records in Table1
where there is no matching record in Table2.
Thanks in advance,
Tim
[Non-text portions of this message have been removed]