我在 Microsoft SQL 服务器中有表;我正在使用 SPSS 14.1。现在我想将 SQL 表连接到 SPSS,所以我可以直接使用 SPSS 中的 SQL 表。
在 SPSS 中,SQL 数据库 -> 数据源 -> 添加新数据库连接 -> 然后我只有 3 个数据源选项:dBASE 文件、Excel 文件和 MS Access 数据库。哪一个可以连接到SQL server?
You should open the Microsoft ODBC Administrator from Start or the Control Panel. There you should activate the System SDN tab, click Add... and add a SQL Server data source.
A wizard will open, where you can enter the details. First the name of the connection, which will be used as a reference by SPSS. Then optionally a description, and the ip address or name of the server.
On the next page select the authentication method, and if needed, enter the user and password. From this point, the default settings will most likely be good. If you will have character coding problems or something like that, you may need to change these settings.
I also use ODBC connection to connect to the database from SPSS, and it works well.
I hope this will help.
您可能需要 MS 的 ODBC 驱动程序或使用 Data Access Pack for SPSS 中的驱动程序,但您需要专门用于 SQL Server 的驱动程序。