Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Unsubscribing Undeliverable Emails that return to the server 1

Status
Not open for further replies.

Rexolio

Technical User
Aug 29, 2001
230
We have a program that sends out emails to subscribed members. The emails are stored in a SQL Server 2000 database. The script we use is initated by a client via the web browser using ASP.

We're beginning to find it harder and harder to keep our database clean of bad email addresses. I'm having a hard time getting my server administrator to work on this problem with me or offer some ideas. So I thought I'd try here.

Is there a way to have undeliverables returned to the server be removed from the database? Am I a moron for thinking this may be possible?

Thanks in advance, everyone!

[bugeyed]
rexolio@bellsouth.net
"I'm not dumb. I just have a command of thoroughly useless information." - Calvin, of Calvin and Hobbes
 
It is indeed possible, it's just the hassle of setting it up.

1. Add a mailbox to your mail server like bounce@yourdomain.com

2. Make the reply-to address of your newsletter or whatever bounce@yourdomain.com (and ideally mention in the email that they should NOT use "reply" to respond to the email)

3. *the tricky part* have your code log into your mail server's bounce account (bounce@yourdomain.com) and parse the emails for the required addresses

4. Remove or flag the email addresses in the database (and delete the bounced email

Obviously 3 needs to be fleshed out. It would be easy in Perl in Java, but in ASP (without 3rd party components) ... hmm .. you make have to make a COM object to connect to the mail server socket and query it.


codestorm
Newbie Life Member.
Fire bad. Tree pretty. - Buffy
<insert witticism here>
 
Thanks, codestorm!

Can anyone point me in the direction of how to go about creating the &quot;tricky part&quot;? That is, the code to log into the email account and then to remove the email addresses from the databases?

Thanks guys. Again, thanks codestorm!

[bugeyed]
rexolio@bellsouth.net
&quot;I'm not dumb. I just have a command of thoroughly useless information.&quot; - Calvin, of Calvin and Hobbes
 
Well, I guess it depends on if you plan to interact with the mail server at a low level (my preference) or not.

Here's some relevant notes I'd made for myself when I was looking into SMTP/POP (It's very terse, having been written on a Palm):
---
Roughly, SMTP is for sending mail and POP is for receiving mail.
POP commands:
USER <username>
PASS <password>
LIST [<message number>]
STAT
LAST
RSET
RETR <message number>
TOP <message number>
DELE <message number>
QUIT
---
You can test this by using telnet to connect to your mail server on port 110.


codestorm
Newbie Life Member.
Fire bad. Tree pretty. - Buffy
<insert witticism here>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top