Let's say I have a user table, and the user can have multiple profiles. When I select using join on user_id I get back two records like so (pseudo-code):
Is there an elegant way for me to get query back in desired form (w/o needing to resort to two queries and patching together a new type)? Any help is much appreciated!