ONJava.com -- The Independent Source for Enterprise Java
oreilly.comSafari Books Online.Conferences.

advertisement

AddThis Social Bookmark Button
Article:
  SQL Subqueries
Subject:   Count the number of record first existing in table at a date
Date:   2006-10-16 20:50:17
From:   Devils
Hi,


I have proble to find the number of single record in a table. e.g.


field A | field B
111 | 1/10/2005
111 | 2/10/2005
222 | 2/10/2005
333 | 2/10/2005
222 | 3/10/2005


I want to know how many record first exist at 2/10/2005. The result should be 2.


i.e.
111 first exist is 1/10/2005 -> not count
222 first exist is 2/10/2005 -> count
333 first exist is 2/10/2005 -> count


Can you help how to do this?


Regards,
Devils


1 to 4 of 4
1 to 4 of 4