I have two arrays: Question and UserProfile
- The
: [] array contain
userProfiles
objects{ id, name }
- The
: [] array contains
questions
objects{ id, text, createdBy }
The
createdBy
userProfiles
Is there a way I could "join" the arrays in much the same way as I would join up two SQL tables if I was using a database.
What I need as an end result is an array that contains
{ id, text, name }
Corresponding SQL would be:
SELECT u.id, q.text, u.name FROM userProfiles u JOIN questions q ON q.createdBy=u.id
Anonymous Asked question May 13, 2021
Recent Comments