Dear all,
It seems the simplest way to do a longest match in Teradata is to use like and qualify rank.
However, it causes large spool during its product join.
And, we cannot use Update /w join to update with only the longest match record, as what Oracle does in PL/SQL.
I find a SQL in this...