add jointure group by