SSIS BIML生成带括号的SQL代码 [英] SSIS BIML generates SQL code with brackets

查看:34
本文介绍了SSIS BIML生成带括号的SQL代码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用 BIML 为 SSIS 动态创建加载包以将数据从 Informix 加载到 SQL Server.问题是这个 BIML 代码产生了下面的 SQL

Im using BIML to dynamically create load packages for SSIS to load data from Informix to SQL Server. The problem is that this BIML code produces the SQL below

<DirectInput>SELECT <#=table.GetColumnList()#> FROM <#=table.GetTag("SourceSchemaQualifiedName")#></DirectInput>

SELECT [column1], [column2], [column3], FROM [mySchema].[mySrcTable]

但是由于括号的原因,这在我的源数据库中不起作用.我可以通过任何方式获取列列表 &动态没有括号的表名?

But that doesnt work in my source database because of the brackets. Any way i can get the columnlist & tablename without the brackets dynamically?

推荐答案

你应该可以使用GetColumnList

<#=table.GetColumnList(string.Empty, """, """)#>

它应该生成一个没有表别名的双引号包裹的列名 - 我认为是 Informix 所期望的.

which should produce a double quote wrapped column name with no table alias - which I think is what Informix expects.

这篇关于SSIS BIML生成带括号的SQL代码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆