In the comments, the optimal value is largely contextual. With that said, my philosophy is this: if the database can do it, let it be.
In particular, for your case, if you do not analyze or manipulate the results - this means that it is strictly for combining all records for output - then I will definitely vote for the database.
source share