PROBLEM:

I would like to transfer a SAS dataset to someone via e-mail.  
Can this be done?

***************************************************************

SOLUTION:

Between UNIX systems
--------------------

SAS Data Sets that have been converted into transport files can be 
transfered via e-mail provided they are uuencoded.  Here are the steps.

On the sending operating system:
-------------------------------

1. Create a transport file using either PROC CPORT (preferred)    
   or PROC COPY (if the receiving system requires this).

2. Create a uuencoded version of the Transport file using UUENCODE:

      uuencode  trans.file  label  >  out.file

   where trans.file is the path/name of the SAS transport file.
         label      the label argument is required.  It is included in 
                    the encoded file's header as the name of the file 
                    into which uudecode is to place the binary (encoded) 
                    data.
         out.file   is the path/name of the newly created uuencoded file.

3. Include out.file in the e-mail message.

NOTE: some eMailers encode attachments automatically using BinHex or
similar devices; if your eMailer has this feature, you may not need
the above instructions to send an encoded SAS data set.


On the receiving operating system
---------------------------------

1) Un-encode the file received via e-mail using UUDECODE.

         uudecode  message.file

   where message.file is the file saved from e-mail.

   The un-encoded file will be a SAS transport file with the name  
   given to it in the uuencode process. 

2) Using PROC CIMPORT (or PROC COPY if the original transport
   file was made with PROC COPY), convert the transport file back into 
   a SAS Data Set.  (Documentation for PROC CPORT, PROC CIMPORT and
   PROC COPY is in the SAS Manuals, and examples can be found 
   elsewhere in this WWWeb site, including:

      http://www.usc.edu/its/doc/statistics/sas/faq/

   and then choose any of several links in the "SAS Across Different
   Systems" section.
 

Between Microcomputers
----------------------

SAS data sets created in SAS for Windows or SAS for Macintosh 
sometimes (please note the implied stress on *sometimes*) can be 
sent as-is through eMail to be used on other microcomputers without 
corruption of the data.  Since there are so many eMail programs 
and procedures available today, it is not possible to
predict or summarize their performance here.  Trial and error
is recommended.

In any case, it is always more reliable to make a SAS Transport
File first.  It is not advisable to compress the file, as each
step of conversion, compression or eMail transfer has some
potential for corruption of the data.  Simple conversion to
a transport file within SAS and then eMailing that transport
file to the recipient should work fine.

The best way, whenever possible, to move SAS data from one
microcomputer to another is on a diskette or Zip disk.  No
translation or conversion takes place and the only variable
in the process is the U.S. Mail or other delivery service.