Simplify left joins by eliminating temporary variables