Data Engineering/data preprocessing

중복제거하고 가장 최신 정보만 가져오기

quantapia 2021. 3. 22. 15:50

SELECT * FROM

( SELECT * , ROW_NUMBER() OVER (PARTITION BY ID ORDER BY REGDATE DESC) AS RN FROM A ) a

WHERE a.RN = 1