Postgres Concatenate Strings Group By Function In R