PDA

View Full Version : SQL query to get all email addresses from unapproved link


John D
01-04-2007, 01:18 PM
Hey,

I'm looking to get the email addresses of all submissions that haven't been approved.

All my unapproved submissions are unpaid, I'm looking to send one email to all unapproved submissions before I remove them from the directory.

Does anyone know what query I would need to get them?

Thanks a lot
John

Tim_Myth
01-04-2007, 02:15 PM
$CheapBastards = $db->GetAll ("SELECT OWNER_EMAIL FROM `{$tables['link']['name']}` WHERE `STATUS` = '1' ");

Should do the trick. :)

fyi...Status:
0 = Inactive (rejected)
1 = Pending
2 = Active (approved)

proprod
01-05-2007, 07:33 AM
Content visible to registered users only.

Oh, wow, that is great :)