Execute a second DB query for each entry returned by a first query
I have a service which, upon accessing a given page, queries a collection in my database based on certain conditions, and the service returns a list of database entries (rows) as expected. One of the fields (columns) it returns is a pointer to an entry in another collection within my database. Now, for each of the entries returned by the first query, I would like to access this second collection and retrieve a field from the entry corresponding to the pointer. Finally, I would like to populate a mobile grid on the page with the entries returned by the first query and the corresponding results from the second query. How can I achieve this?