| Date: | Wed, 4 Nov 2009 17:35:07 -0500 |
| Reply-To: | "Kevin F. Spratt" <Kevin.F.Spratt@DARTMOUTH.EDU> |
| Sender: | "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU> |
| From: | "Kevin F. Spratt" <Kevin.F.Spratt@DARTMOUTH.EDU> |
| Subject: | Proc Import and export of MS Access Tables |
| Content-Type: | text/plain; charset="us-ascii"; format=flowed |
|---|
The following two procedures have worked for me for several years and
are still currently
working under SAS 9.2 in the Windows XP 32-bit environment.
The two procedures are embedded in a macro and the macro variables
indicate data set names
and access table names.
I am now trying to run these macros on SAS 9.2 in Windows XP 64-bit
with a 64-bit version of SAS 9.2 with
no joy.
The error messages suggests that the Access2002 and excel2002 engines
may not be available. If this
is the case, how do I determine if this version of SAS has these
engines installed and activated and, if
so, determine that the problem is something else?
If I do need to add these engines, it probably means that I needed to
do this before, but I have no recollection
of what I did so any assistance there would be helpful.
It just occured to me that I don't currently have MS Office installed
on the 64-bit machine, does proc import
and export in SAS or the SQL stables in the procedures need MS office
to be installed?
**********************************************************************************;
PROC IMPORT OUT =
&DATA
TABLE =
&DATA
DBMS = ACCESS2002
REPLACE;
USEDATE = YES; * FORCE DATE DATA TO
STRIP TIME COMPONENT;
DATABASE ="&DRV&PRJ&DB"; * location of access
data base (.MDB)
file;
RUN;
PROC EXPORT
DATA=WORK.XXX
DBMS =
EXCEL2002 REPLACE
FILE =
"&DRV&PRJ.\DOC\&PNAME..&date..XLS";
SHEET = &DATA._COMPARE; * produce multiple
sheets in a single workbook;
RUN;
______________________________________________________________________
Kevin F. Spratt, Ph.D.
Department of Orthopaedic Surgery
Dartmouth Medical School
One Medical Center Drive
DHMC
Lebanon, NH USA 03756
(603) 653-6012 (voice)
(603) 653-6013 (fax)
Kevin.F.Spratt@Dartmouth.Edu (e-mail)
_______________________________________________________________________
|