PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
I would like to e-mail all addresses associated within a ticket, except, if their name exists more than once, omit duplicates...
so that everyone only gets one email, instead of the 36 that i got from the tests that i am doing.
What would detect duplicate entries before the loop?
I would like to e-mail all addresses associated within a ticket, except, if their name exists more than once, omit duplicates...
so that everyone only gets one email, instead of the 36 that i got from the tests that i am doing.
What would detect duplicate entries before the loop?
We really need to see some code that's kinda vague
Where are the email addresses stored? In an array == array_unique(). In MySQL == distinct.
$sql3 = "SELECT * FROM it_mem WHERE Mem_ID=".$assignTo." GROUP BY Mem_Email";
//or
$sql3 = "SELECT DISTINCT Mem_Email, Mem_FName FROM it_mem WHERE Mem_ID=".$assignTo;
You're basically asking your query not to return duplicates