Add more join with aggregate into sql coverage tests