Click to See Complete Forum and Search --> : data in email ---> database


YaRness
07-17-2001, 11:18 AM
ok say i've got a database. i've got people sending email to somespecialaddress@mycompany.com. the stuff i want is in the body of the message, no attachments.

i could:

1) run a retrieval when i start up the database client. pretty easy in *nix, just parse out stuff from the email file (i forget where that is atm, but i know there's just plain old text files somewhere to grok). i would assume that windows servers would have something at least vaguely similar (*crosses fingers).

2) prolly a better method: have some daemon that harvests stuff from the emails when they are received and plugs them into a database (prolly into a queue table of some sort for later entry into other tables, but these are details that we don't really care about just yet). this i'm sure could be done in *nix, but i'm not familiar with how (yet). setting up something like that in windows sounds really scary as well.

3) ?

later of course all of these this will include some method of decryption, since the emails will prolly be PGP (or some other standard) encrypted.

this will almost certainly be a sql database (prolly mysql), but i dunno if that detail is important atm.
basically i guess i'm looking for a kick in the right direction, or any other comments.

hux
07-17-2001, 11:53 AM
Hi,
Just a thought, since I didn't see you mention it anywhere...for the sake of your data integrity, make em fill out a form...use drop down menus..else you'll get:

pittsburg
Pittsburg
Pitsburgh
pittsburgh

you get the idea...this from a database nerd.

YaRness
07-17-2001, 12:12 PM
i didn't mention it: the email will be coming from auto-generated sources. thanks for mentioning it though.

takshaka
07-17-2001, 03:59 PM
I've used Perl with Mail::Audit (http://search.cpan.org/search?dist=Mail-Audit) to do something similar before. On *nix, it's as simple as piping to your app from a .forward file or equivalent. How feasible this is on Windows, I don't know; I have less than zero knowledge of MS MTAs.

YaRness
07-17-2001, 04:08 PM
my project manager keeps mentioning perl :D

this will eventually (or primarily) be a web-based (CGI --> database) thingamajig. i might try and look for, or write, something that would making plugging in some email support nice and easy.

all this design makes my brain hurt.