LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (May 2007, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Sat, 12 May 2007 15:52:16 -0500
Reply-To:   Gregg Snell <sas-l@DATASAVANTCONSULTING.COM>
Sender:   "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:   Gregg Snell <sas-l@DATASAVANTCONSULTING.COM>
Subject:   Re: unix mail vs pc mail
Comments:   To: "Terjeson, Mark" <Mterjeson@RUSSELL.COM>
In-Reply-To:   <16FD64291482A34F995D2AF14A5C932C015A736E@MAIL002.prod.ds.russell.com>
Content-type:   text/plain; charset=us-ascii

Mark,

I prefer to shell-out and let Unix send the email. The trick for attachments is that you need to use the Unix mailx command rather than mail. Also, I've found that uuencode will prevent some problems with certain attachments (you can also change the attachement name):

%sysexec uuencode /home2/tmp/xxtest.csv xxtest.xls | mailx -s "Test: Sample" myeaddr@mydomain.com;

Regards, Gregg Snell

-----Original Message----- From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Terjeson, Mark Sent: Saturday, May 12, 2007 2:55 PM To: SAS-L@LISTSERV.UGA.EDU Subject: unix mail vs pc mail

Hi All,

Regardless if I place the attachment info in the FILENAME or place it in the body of the email -- it arrives in the email for Windows as an attachment when using SAS v8.2, and for SAS v8.2 on unix(AIX) the same code appends the csv contents to the body instead of as an attachment.

Anybody know the tricks to actually make an attachment in SAS v8.2 for Unix(AIX)? I thought I used to send attachments via unix years ago, but current enviroment is not. Is there a setting or trick anyone can think of?

/* filename mymail email "myeaddr@mydomain.com" Subject="Test: Sample" attach="/home2/tmp/xxtest.csv"; */

filename mymail email "myeaddr@mydomain.com" Subject="Test: Sample" ;

data _null_; file mymail lrecl=32767; put '!EM_ATTACH! ' "/home2/tmp/xxtest.csv"; put; put "This is an test mailing."; put; run;

Thanks in advance, Mark


Back to: Top of message | Previous page | Main SAS-L page