SAS OLEDB连接和Teradata易失性表

时间:2016-04-01 22:32:33

标签: sql database sas teradata proc

我有一些没有SAS access for Teradata Installed

的SAS开发人员

并且它们不在SAS查询网格上。相反,他们使用OLEDB连接到Teradata。 OLEDB似乎不喜欢创建volatile表语句。有没有人有运气使用它并让VT在teradata工作

这是SAS W2K服务器上安装的内容

     proc setinit; run;


  ---Base SAS Software
            30DEC2016
    ---SAS/STAT
            30DEC2016
    ---SAS/GRAPH
            30DEC2016
    ---SAS/Secure 168-bit
            30DEC2016
    ---SAS/Secure Windows
            30DEC2016
    ---SAS/ACCESS Interface to PC Files
            30DEC2016
    ---SAS/ACCESS Interface to ODBC
            30DEC2016
    ---SAS/ACCESS Interface to OLE DB
            30DEC2016
    ---SAS Workspace Server for Local Access
            30DEC2016
    ---High Performance Suite
            30DEC2016

我可以看到ODBC,但我不确定..这应该是指TD的ODBC驱动程序以及如何使用而不是OLEDB?

(create multiset volatile table VT (C1 integer, C2 date))

上面的测试代码失败,并显示它需要create table语句中的列名。额外的R& L括号是因为它嵌入在SAS中 但如果我删除Volatile语句,它将运行良好。

以下是详细错误

    proc sql;
  connect to OLEDB(Provider='MSDASQL' Extended_Properties='DRIVER={Teradata};DBCNAME=SITEPRD;AUTHENTICATION=ldap' UID="&DMID" PWD="&DMPWD");
  execute (create multiset volatile table idlist (my_id integer, mydate date)
  ON COMMIT PRESERVE ROWS) by teradata;
  execute (COMMIT WORK) by teradata;
  insert into idlist
  select distinct MyId_sas, mydate
  from mysource;
quit; 3:52 PM 
And got this output: 3:52 PM 
proc sql;
28     connect to OLEDB(Provider='MSDASQL' Extended_Properties='DRIVER={Teradata};
28 ! DBCNAME=SITEPRD;AUTHENTICATION=ldap' UID="&DMID" PWD="&DMPWD");
SYMBOLGEN:  Macro variable DMID resolves to ConfusedUser
SYMBOLGEN:  Macro variable DMPWD resolves to Youbetcha!

29     execute (create multiset volatile table idlist (my_id integer, mydate date)
30     ON COMMIT PRESERVE ROWS) by teradata;
ERROR: The TERADATA engine cannot be found.
ERROR: A Connection to the teradata DBMS is not currently supported, or is not installed at
       your site.
31     execute (COMMIT WORK) by teradata;
ERROR: The TERADATA engine cannot be found.
ERROR: A Connection to the teradata DBMS is not currently supported, or is not installed at
       your site.
32     insert into idlist
33     select distinct MyId_sas, mydate
34     from mysource;
ERROR: File WORK.idlist.DATA does not exist.
NOTE: SGIO processing active for file WORK.mysource.DATA.
35   quit;
NOTE: The SAS System stopped processing this step because of errors.
NOTE: PROCEDURE SQL used (Total process time):
      real time           9.19 seconds
      cpu time            1.75 seconds 

0 个答案:

没有答案