generating correct filtering and sorting code for fields joined with outer joins