我需要使用“执行 SQL 任务”组件在 SSIS 的变量中加载货币值。 我将 SELECT 的返回列映射到一个变量。 我已将变量“UnknownMoney”声明为 Double 或 Single,但我总是收到错误消息:
Error: 0xC002F309 at Load Dummy vars, Execute SQL Task: An error occurred while assigning a value to variable "UnknownMoney": "The type of the value being assigned to variable "User::UnknownMoney" differs from the current variable type. Variables may not change type during execution. Variable types are strict, except for variables of type Object.".
SSIS 中的 Money 列类型是 DT_CY(货币),但此类型不适用于变量。
Money 的正确类型是什么?
编辑:VS2012 中的变量类型下拉列表框:
最佳答案
SSIS 有一个货币数据类型。
SQL 有一个货币类型。
这些是兼容的。
关于types - 什么变量类型用于表示 SSIS 中的 Money,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3990107/