Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Other Forums
 MS Access
 How do we find different records by date?

Author  Topic 

ozkan
Starting Member

3 Posts

Posted - 2010-07-27 : 02:45:33
Hi,
For example, the following is a table.

A Date
x 01.01.2010
y 01.01.2010
z 01.01.2010
x 02.01.2010

A column I want to get the records that are different but if date column is different I want to get the records again.
In this way, how do I do a sql query?

Kristen
Test

22859 Posts

Posted - 2010-07-27 : 02:52:23
Something like this perhaps?

SELECT DISTINCT A, Date FROM MyTable

or

SELECT A, Date, COUNT(*) AS MyCount
FROM MyTable
GROUP BY A, Date
Go to Top of Page
   

- Advertisement -