Basically I need to extract a list of distinct email addresses and their count of how many times they are used, in the list
the message fields look like this "Vc (VC Email - Dev)" <email@example.com>, firstname.lastname@example.org
...delimited by a comma, sometimes with friendly name sometimes not, any help would be appreciated.
FROM tblawm_messages a
JOIN tblEmailFile b ON a.MessageId = b.MessageId and b.IsMatch = 1
WHERE a.VcAccountId = 9
ORDER BY b.FolderID