Improve implementation of left_outer_join