Quantcast
Channel: Teradata Forums - Database
Viewing all articles
Browse latest Browse all 14773

qualify rank() over (partition) - question - response (1) by dnoeth

$
0
0

It's hard to guess without any details about the rules you want to implement.

select * from tab
qualify rank() over (partition by inr, rd order by dt desc, ct1 desc, ct2 desc) = 1

 
Dieter


Viewing all articles
Browse latest Browse all 14773

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>