Newbie trying to use Python with Sendmail and MySQL

Sam Penrose see at message.body
Sat Aug 26 00:24:48 EDT 2000


In article <39A43CA2.C406F420 at onebox.com>, jtulabing at onebox.com wrote:

> I am attempting to receive a mail message, and then push all the data
> within the message to a MySQL database.  Is there already a tool or app
> that already does this?  If not, is Python the best way to go?

1) I am not sure if there is a module for *receiving* email (although 
mailbox.py in the standard distribution sure looks like one). Assuming 
the mail is just a text file on your drive, you could read it in as with 
any file.

2) If you're running on *nix, you'll need MySQLdb.py (current version 
approx. 0.2.1), which can be less than fun to compile. Search recent 
postings for commentary. MySQLdb.py allows you to write standard SQL 
strings to MySQL.

-- 
spenrose at well dot com



More information about the Python-list mailing list