【问题标题】:ODBC issue with SQL-Server date field when migrating from XP32 to Win7 64从 XP32 迁移到 Win7 64 时,SQL-Server 日期字段的 ODBC 问题
【发布时间】:2011-10-24 06:32:45
【问题描述】:

我正在 SAS 中运行 SQL 传递查询。

当我在我的 32 位 WinXP 机器上运行它时,最终 SAS 表中的日期字段是数字。

当我在我的 64 位 Win7 机器上运行它时,最终 SAS 表中的日期字段是字符。

有没有其他人遇到过这个问题?如何让 64 位版本始终返回数字(最好在迁移环境时不更改代码)?

谢谢 抢

proc sql noprint;
  connect to odbc as remote (datasrc=xxx);
  create table table1 as 
  select *
  from connection to remote
  (
  select cast(date_created as date) as date,
         count(*) as count
  from mydb.dbo.mytable
  group by cast(date_created as date)
  order by date
  )
  ;
  disconnect from remote;
quit;



解决方案: 需要安装“SQL Server Native Client 10”。在此处下载 64 位安装:

http://www.microsoft.com/download/en/confirmation.aspx?id=16177

然后使用该新驱动程序重新设置 DSN 并修复它。

【问题讨论】:

    标签: sql-server windows-7 64-bit odbc sas


    【解决方案1】:

    解决方案:需要安装“SQL Server Native Client 10”。在此处下载 64 位安装:

    http://www.microsoft.com/download/en/confirmation.aspx?id=16177

    然后使用该新驱动程序重新设置 DSN 并修复它。

    【讨论】:

      猜你喜欢
      • 2016-07-26
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-12-25
      • 2011-12-18
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多