I have a view with 270677 rows.and I have the one of the column as_of_date.
I want to get the distinct as_of_date from that view.But the query is running so long(it'staking 30sec's) But I have to display this less than that time.
Please give me some idea
and I am ruuning the query
select convert(varchar(10),as_of_date,120) as asofdate from xxxx group by as_of_date order by as_of_date desc