`awk '!a[$0]++'` is one of the most famous Awk one-liners. It eliminates line based duplicates while retaining input order. And it is pretty easy to adapt this for particular fields instead of whole lines.
This video is based on content from my "GNU AWK" ebook: https://github.com/learnbyexample/lea...