简体   繁体   English

在Teradata中使用SAS格式

[英]Using SAS formats in Teradata

I've been using the SAS 9.3 macro INDTD_PUBLISH_FORMATS to publish formats in Teradata 14. It all works fine, but what I can't see is where the published formats are stored. 我一直在使用SAS 9.3宏INDTD_PUBLISH_FORMATS在Teradata 14中发布格式。一切正常,但是我看不到已发布格式的存储位置。 The macro creates a series of Teradata functions (SAS_PUTx) that are called when a format is invoked by SAS. 宏创建一系列Teradata函数(SAS_PUTx),当SAS调用格式时会调用这些函数。 Through the external name parameter of the function, there is a path back to the WORK directory on the SAS server and I can see the formats there. 通过该函数的外部名称参数,可以找到一个返回SAS服务器上WORK目录的路径,我可以在其中看到格式。 However even when I delete this directory, the formats still work ok. 但是,即使删除该目录,格式仍然可以正常工作。 I have no idea where Teradata is storing them. 我不知道Teradata在哪里存储它们。 Could it be caching them somewhere? 可以将它们缓存在某个地方吗? SAS Support seem unable to replicate this behaviour. SAS支持人员似乎无法复制此行为。 Thanks 谢谢

%INDTD_PUBLISH_FORMATS macro would have published the format as a UDF on Teradata database. %INDTD_PUBLISH_FORMATS宏会将其格式作为UDF发布到Teradata数据库上。 Check out "Overview of the Publishing Process" .The macro performs the following tasks: 签出“发布过程概述” 。宏执行以下任务:

1) creates .h and .c files, which are necessary to build the SAS_PUT() function. 1)创建.h和.c文件,这是构建SAS_PUT()函数所必需的。

2) produces a script of Teradata commands that are necessary to register the SAS_PUT() function in the Teradata EDW. 2)生成Teradata命令的脚本,这些脚本是在Teradata EDW中注册SAS_PUT()函数所必需的。

3) uses SAS/ACCESS Interface to Teradata to execute the script and publish the files to the Teradata EDW. 3)使用SAS / ACCESS接口对Teradata执行脚本并将文件发布到Teradata EDW。

You can try using SHOW FUNCTION SAS_PUT on teradata to check the function. 您可以尝试在teradata上使用SHOW FUNCTION SAS_PUT来检查功能。 Try going through section "Format Publishing Macro Example" . 尝试阅读“格式化发布宏示例”一节

Also, the following link provides information on how the whole publishing thing happens : SAS(R) 9.3 In-Database Products: User's Guide, Fourth Edition -> How it Works 另外,以下链接提供了有关整个发布过程的信息: SAS(R)9.3数据库内产品:用户指南,第四版->工作原理

Hope this helps. 希望这可以帮助。

Thanks! 谢谢!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM