in reply to Mass Mail
Even if you don't use them here, you absolutely must check to see if your open call succeeded:
Since we can't tell right now if that worked, your program could be correct all over except for an open path or something... this is the first place I'd look. Same goes for the system call, as a matter of fact. (And on there, it's more secure to pass it a list of options rather than a string. You can avoid shell interpolation that way -- a good thing to do. However, as you appear to be on a Windows machine, the amount of damage someone can do with the default shell is lower than on Unix.)### Opens the file to place content to be e-mailed open (F, ">$nice") || die "Can't open $nice: $!";
As a side note, and having not worked with Access very much, I wonder why you don't move the 'country eq US' comparison into your SQL statement. A good relational database will be able to perform this faster than you can in Perl:
As a nice side effect, you don't have to do two DB queries, which may solve some other things (I'm not sure that issuing a new query to the Perl ODBC object while fetching from an older query is anything but trouble).### Sql statement my $statement="SELECT web_id, mail_alias FROM lexnex_ids WHERE countr +y = 'US'";
I hope this helps.
|
|---|