Qualify ( ) allows filtering and basically behaves like a having clause with order descending in its default syntax. Assuming frm_dt is a date, looks like your query is simply getting the latest exchange rate per from/to exchange currency combination.
Hi Adeel, oif course you're right, it's working on Teradata. But the original poster wanted to port it to Oracle :-)
Select frm_crncycd,to_crncycd,exch_rate from (Select frm_crncycd,to_crncycd,exch_rate, rank() over (partition by frm_crncycd,to_crncycd order by frm_dt desc) as rnk from exchange_rate ) dt where rnk = 1