Excluding records

T

tdabel

Good day all.

I require assistance in developing a Query that will exclude records when a
columns field data changes based on the same date.

My structure is as such:

[Date] [Product]
8/23/07 xxxxx
8/23/07 xxxxx
8/24/07 xxxxx
8/24/07 ccccc
8/25/07 xxxxx
8/25/07 xxxxx

I would like to exclude 8/24/07 records from the Query.

All assistance is much appreciated.

Sincerely,

Tony D. Abel
 
K

KARL DEWEY

Try these queries ---
tdabel_1 ---
SELECT Products.ProdDate, Products.Product
FROM Products
GROUP BY Products.ProdDate, Products.Product;

tdabel_2 ---
SELECT tdabel_1.ProdDate
FROM tdabel_1
GROUP BY tdabel_1.ProdDate
HAVING (((Count(tdabel_1.ProdDate))>1));


SELECT Products.ProdDate, Products.Product
FROM Products LEFT JOIN tdabel_2 ON Products.ProdDate = tdabel_2.ProdDate
WHERE (((tdabel_2.ProdDate) Is Null));
 
T

tdabel

Karl, thanks a lot. The second suggestion work well for me.

Sincerely,

Tony D. Abel

KARL DEWEY said:
Try these queries ---
tdabel_1 ---
SELECT Products.ProdDate, Products.Product
FROM Products
GROUP BY Products.ProdDate, Products.Product;

tdabel_2 ---
SELECT tdabel_1.ProdDate
FROM tdabel_1
GROUP BY tdabel_1.ProdDate
HAVING (((Count(tdabel_1.ProdDate))>1));


SELECT Products.ProdDate, Products.Product
FROM Products LEFT JOIN tdabel_2 ON Products.ProdDate = tdabel_2.ProdDate
WHERE (((tdabel_2.ProdDate) Is Null));

--
KARL DEWEY
Build a little - Test a little


tdabel said:
Good day all.

I require assistance in developing a Query that will exclude records when a
columns field data changes based on the same date.

My structure is as such:

[Date] [Product]
8/23/07 xxxxx
8/23/07 xxxxx
8/24/07 xxxxx
8/24/07 ccccc
8/25/07 xxxxx
8/25/07 xxxxx

I would like to exclude 8/24/07 records from the Query.

All assistance is much appreciated.

Sincerely,

Tony D. Abel
 
K

KARL DEWEY

What I posted was not multiple suggestions but all three queries were
required.

If you can do subqueries then you could use query one and two as subs in the
last one.
--
KARL DEWEY
Build a little - Test a little


tdabel said:
Karl, thanks a lot. The second suggestion work well for me.

Sincerely,

Tony D. Abel

KARL DEWEY said:
Try these queries ---
tdabel_1 ---
SELECT Products.ProdDate, Products.Product
FROM Products
GROUP BY Products.ProdDate, Products.Product;

tdabel_2 ---
SELECT tdabel_1.ProdDate
FROM tdabel_1
GROUP BY tdabel_1.ProdDate
HAVING (((Count(tdabel_1.ProdDate))>1));


SELECT Products.ProdDate, Products.Product
FROM Products LEFT JOIN tdabel_2 ON Products.ProdDate = tdabel_2.ProdDate
WHERE (((tdabel_2.ProdDate) Is Null));

--
KARL DEWEY
Build a little - Test a little


tdabel said:
Good day all.

I require assistance in developing a Query that will exclude records when a
columns field data changes based on the same date.

My structure is as such:

[Date] [Product]
8/23/07 xxxxx
8/23/07 xxxxx
8/24/07 xxxxx
8/24/07 ccccc
8/25/07 xxxxx
8/25/07 xxxxx

I would like to exclude 8/24/07 records from the Query.

All assistance is much appreciated.

Sincerely,

Tony D. Abel
 
T

tdabel

Karl, I used the second select method with other criterions and I received
the desire results.

Sincerely,

Tony D. Abel

KARL DEWEY said:
What I posted was not multiple suggestions but all three queries were
required.

If you can do subqueries then you could use query one and two as subs in the
last one.
--
KARL DEWEY
Build a little - Test a little


tdabel said:
Karl, thanks a lot. The second suggestion work well for me.

Sincerely,

Tony D. Abel

KARL DEWEY said:
Try these queries ---
tdabel_1 ---
SELECT Products.ProdDate, Products.Product
FROM Products
GROUP BY Products.ProdDate, Products.Product;

tdabel_2 ---
SELECT tdabel_1.ProdDate
FROM tdabel_1
GROUP BY tdabel_1.ProdDate
HAVING (((Count(tdabel_1.ProdDate))>1));


SELECT Products.ProdDate, Products.Product
FROM Products LEFT JOIN tdabel_2 ON Products.ProdDate = tdabel_2.ProdDate
WHERE (((tdabel_2.ProdDate) Is Null));

--
KARL DEWEY
Build a little - Test a little


:

Good day all.

I require assistance in developing a Query that will exclude records when a
columns field data changes based on the same date.

My structure is as such:

[Date] [Product]
8/23/07 xxxxx
8/23/07 xxxxx
8/24/07 xxxxx
8/24/07 ccccc
8/25/07 xxxxx
8/25/07 xxxxx

I would like to exclude 8/24/07 records from the Query.

All assistance is much appreciated.

Sincerely,

Tony D. Abel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top