Question

I'd like to incorporate this command line in a postgres 8.4 version function:

echo "this is the body" | mail -s "subject" -r sender@sender.com "recepient@recepient.com"

Is it possible?

I looked at this googling it but I can't use sendmail, is there something similar I could use but instead of sendmail, just mail?:

open(MAIL, "|/usr/sbin/sendmail -t") or
die 'Cannot send mail';
print MAIL "From: $from\n";
print MAIL "To: $to\n";
print MAIL "Subject: $subject\n\n";
print MAIL "$content";

No correct solution

Licensed under: CC-BY-SA with attribution
Not affiliated with dba.stackexchange
scroll top