Código SQL:
Ver originalCREATE TABLE #temp
(
id INT,
nombre VARCHAR(20),
fecha datetime
)
INSERT INTO #temp VALUES (1,'roger','01/05/2014')
INSERT INTO #temp VALUES (1,'jorge','01/07/2014')
INSERT INTO #temp VALUES (1,'ana','03/15/2014')
INSERT INTO #temp VALUES (2,'perez','01/27/2014')
INSERT INTO #temp VALUES (3,'lucia','05/13/2014')
INSERT INTO #temp VALUES (3,'alberto','01/10/2014')
INSERT INTO #temp VALUES (4,'Ilda','07/01/2014')
SELECT t1.* FROM #temp AS t1
INNER JOIN (SELECT MAX(fecha) fecha,id FROM #temp GROUP BY id ) AS t2 ON (t1.fecha=t2.fecha AND t1.id=t2.id)
ORDER BY id ASC
Resultado:
id nombre fecha
----------- -------------------- -----------------------
1 ana 2014-03-15 00:00:00.000
2 perez 2014-01-27 00:00:00.000
3 lucia 2014-05-13 00:00:00.000
4 Ilda 2014-07-01 00:00:00.000