[英]ADF - Access #table or Temp table used in Script task activity output to be used in Copy activity as source
We have simple script consider the one below as an example.我们有简单的脚本,以下面的脚本为例。
Script:脚本:
create table #tableABC (
col A varchar(10),
col B varchar(10),
col C varchar(10)
)
insert into #tableABC
select 'A' ,'B', 'C'
The above script is considered as an SP and excepted in script task and it works.上面的脚本被认为是一个 SP 并且在脚本任务中被排除并且它有效。 but we are unable to access the #table in the following copy activity
但是我们无法访问以下复制活动中的#table
select * from #tableABC;
Azure data factory doesn't support automatic temporary table creation and we cannot set table name with ## as starting. Azure 数据工厂不支持自动创建临时表,不能设置以##开头的表名。
How to create temp tables in SQL to be used in several ADF activities? 如何在 SQL 中创建临时表以用于多个 ADF 活动?
Refer the above link, which has lot of suggestions.参考上面的链接,里面有很多建议。
https://github.com/MicrosoftDocs/azure-docs/issues/35449 https://github.com/MicrosoftDocs/azure-docs/issues/35449
Also refer the above blog for additional support.另请参阅上述博客以获得更多支持。
Note: Do not close the SQL connection session after creating temporary table.注意:创建临时表后不要关闭SQL连接session。
Alternate suggestion:替代建议:
Instead of using the Temp Tables, use the table type for easy usage.不使用临时表,而是使用表类型以便于使用。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.