Trying to create a notification mail to my clients that have invoices due.
Here is my table
Name Amount Duedate
Joe@blah 10.00 2011-04-13
Joe@blah 15.00 2011-04-13
Jill@ugg 20.00 2011-05-20
Jim@yuck 25.00 2011-04-13
Joe@blah 15.00 2011-05-20
Because Joe is in there twice, how do I supress the second joe, so I don’t notify him twice. I’d like it to return only:
Joe@blah
Jim@yuck
How do i do this in mysql?
Thanks
Since you’re only selecting on Name the DISTINCTROW will only return one instance of each Name.