Hi to u all, I'm using a SELECT that through a JOIN extracts a recordset like that:
username, email, favourite hobby
where each user has many hobbies.
So for example output could look like this:
Paul, paul@mail.com, fishing
Paul, paul@mail.com, chess
David, david@mail.com, art
...
I need to compose 1 e-mail for each user, resuming all his hobbies. So I need to send one e-mail to Paul telling him:
Hi Paul, your hobbies are:
1. fishing
2. chess
I'm wondering how to work this out: we are talking of about 5000 user, so I think it would be a stress for mySQL to create a SELECT and then inner SELECT for each username!
As an old ASP developer I was used to putting Recordset results in two arrays, and then use nested loops...how can I manage this in PHP?
Thanks in advance, hope this all makes sense and someone can give help!