Database Reference
In-Depth Information
1.3.5 Converting Excel Tables to Text
This example starts by deleting the blank line in row 2 of the Excel spreadsheet from Figure 1.3.4 and
copying the data from Figure 1.3.4 (cols C to I) into a Microsoft Word document and making the table
borders visible. The second step is to place that same data into the SAS Enhanced Editor window and then
copy the data from there into Microsoft Word. The results are shown in Figure 1.4.2a.
Figure 1.4.2a: A Microsoft Word Document with Two Copy and Paste Outputs.
1.4 Accessing Excel Data from the SAS Explorer Window and Toolbar
I could have called this section “ Accessing Excel Data Using the SAS Export/Import Wizards, ” but not
all of the methods I describe here use the wizards. When using SAS without SAS/ACCESS Interface to PC
Files software, the conversion methods are very limited. The next six examples show how to access the
SAS Export wizard, Import wizard, and other conversion methods directly from the SAS Explorer window
and the SAS toolbar. I will show you how to do this without writing SAS code to do the conversion. Only
two of these routines write SAS code for you. These methods allow you to save the code wherever you can
write a data file. These two methods are the Export/Import wizards within SAS. They can be found on the
“File” menu of the toolbar. As the names imply, the Export wizard sends data to Excel, and the Import
wizard reads data from Excel. The examples shown here will use the SASHELP.SHOES data set. They
send data to and read data from Excel without writing any SAS code. Within this topic I treat the
Export/Import wizards differently than PROC EXPORT and PROC IMPORT. The reason I treat them
differently is because the wizards do the work for you and provide only a limited number of option
selections, while the procedures require more knowledge about the software and the options that are
 
Search WWH ::




Custom Search