在64位SAS中使用libname语句与32 Excel进行交互 [英] Using libname statement in 64 bit SAS to interact with 32 Excel

查看:397
本文介绍了在64位SAS中使用libname语句与32 Excel进行交互的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我安装了64位SAS 9.4和32位Office2007.当我安装32位SAS 9.3时,我可以使用libname语句,其中Excel文件是库,句点后是"filename"实际上是Excel文件中的工作表或命名范围.例如,您从一个libname语句开始

I have 64 bit SAS 9.4 installed and 32 bit Office 2007. When I had 32 bit SAS 9.3 installed, I was able to use a libname statement where the Excel file was the library and the "filename" that follows after the period was in fact a worksheet or named range in the Excel file. For example, you start with a libname statement

libname exceltst path="C:\Users\username\Documents\test.xlsx";

然后,稍后您可以使用exceltst.stuff引用其中的命名范围,假设"stuff"是命名范围.

And, then later you can reference a named range in this with exceltst.stuff, assume "stuff" is a named range.

那么,这仍然可行吗?我猜想它与64位sas和32位excel有关,但是我想知道是否有些变化仍然有效.我可以使用proc导出功能将其导出到excel文件,并且工作正常,但是我尝试了20个libname的变体,但无法使其正常工作.我得到的错误是:

So, is this still possible? I am guessing it has to do with 64 bit sas and 32 bit excel but I am wondering if there is some variation that still works. I am able to use a proc export to export to the excel file and it works just fine but I have tried 20 variations on the libname and can't get it to work. The error I get is:

ERROR: Connect: Class not registered
ERROR: Error in the LIBNAME statement.

推荐答案

如果可以安装SAS PC Files Server,仍然可以在PCFILES目标位置执行此操作.安装PC Files Server软件不在此处的答案范围内,但有关说明,请谷歌搜索,它们随时可用.您可以将PC Files Server安装在台式机上,也可以将它安装在中央服务器上(如果对您的工作场所更方便).

If you can install SAS PC Files Server, you can still do this with the PCFILES destination. Installing the PC Files Server software is out of the scope of an answer here, but google about for instructions, they are readily available. You can install the PC Files Server on your desktop, or on a central server if that's more convenient for your workplace.

安装后,只需通过以下方式访问它:

Once you have it installed, you just access it by:

libname mylib pcfiles path="blah\blah\blah.xlsx";

就像以前一样,但是具有不同的dbms类型.

Just like you did before, but with a different dbms type.

这篇关于在64位SAS中使用libname语句与32 Excel进行交互的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆