Go with (g)awk
, it’s capable :-), here is a solution, but please note: it’s only working with the exact html table format you had posted.
awk -F "</*td>|</*tr>" '/<\/*t[rd]>.*[A-Z][A-Z]/ {print $3, $5, $7 }' FILE
Here you can see it in action: https://ideone.com/zGfLe
Some explanation:
-
-F
sets the input field separator to a regexp (any oftr
‘s ortd
‘s opening or closing tag -
then works only on lines that matches those tags AND at least two upercasse fields
-
then prints the needed fields.
HTH