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

Selecting a column based on DATE along with GROUP BY - response (2) by M.Saeed Khurram

$
0
0

Hi,
You can try this

SELECT (SEL UID FROM TD3471.TEMP WHERE dt=(SEL MAX(dt) FROM TD3471.TEMP )) AS GID, MID
FROM TD3471.TEMP
ORDER BY 2;

 


Viewing all articles
Browse latest Browse all 14773

Trending Articles



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