Re: Analytic troubles

From: hrishy <hrishys_at_yahoo.co.uk>
Date: Mon, 10 Nov 2008 10:16:33 +0000 (GMT)
Message-ID: <531423.92156.qm@web27406.mail.ukl.yahoo.com>


Hi

Does this work.
From the top of my head didnt test

select min(date_form),name
from (

select 	date_form,
	name,
	lead(name,1,0)
	over(order by date_form) next_name

from table1
) x
where (x.name=x.next_name OR x.name<>x.next_name) group by name

regards
Hrishy       

--
http://www.freelists.org/webpage/oracle-l
Received on Mon Nov 10 2008 - 04:16:33 CST

Original text of this message