id____ project_id_____year
1________1____________2010
2________1____________2008
3________1____________2009
4________2____________2007
5________2____________2009
id________project_id_____year
2____________1___________2008
4____________2___________2007
SELECT ID, PROJECT_ID, YEAR
FROM PROJECT AS P1
JOIN (SELECT PROJECT_ID, MIN(YEAR) AS YEAR
FROM PROJECT
GROUP BY PROJECT_ID
) AS P2
ON P1.PROJECT_ID = P2.PROJECT_ID AND P1.YEAR = P2.YEAR
SELECT ID, PROJECT_ID, YEAR
FROM PROJECT
WHERE (PROJECT_ID, YEAR) IN
(
SELECT PROJECT_ID, MIN(YEAR) AS YEAR
FROM PROJECT
GROUP BY PROJECT_ID
)