Strengthen query generation when NULLs are involved; fix table join types.