Databricks implements max_by and min_by, which is similar to keep (dense_rank last order by) :
select id,
max_by(column_a, column_b)
from table_name
group by id;
Both functions can also be invoked as a window function using the OVER
clause.