分配给变量“XXXXX”的值的类型。与当前变量类型不同 [英] The type of the value being assigned to variable "XXXXX" differs from the current variable type

查看:91
本文介绍了分配给变量“XXXXX”的值的类型。与当前变量类型不同的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,我在SQL Server 2008中有一个列,我将其存储为BIGINT。我将在SSIS中使用列的数据,并将变量声明为INT64数据类型。当我执行SSIS时,它会返回错误消息作为上面的标题。

我该如何解决这个问题?好像是SSIS中的一个错误。



我计划将SQL中的数据类型更改为INT,将SSIS中的数据类型更改为INT32,但在我使用最后一个选项之前,我我想听听这里的任何建议。谢谢。



我的尝试:



1.更改SSIS中的数据类型从INT64到String在线建议并在SQL中作为BIGINT保留数据类型但不起作用。

Hi I have a column in SQL Server 2008 in which I stored as BIGINT. I will use the column's data in SSIS and I declare the variable as INT64 data type. When I execute the SSIS, it returns me the error message as title above.
How can I solve the issue? Seems like a bug in SSIS.

I plan to change the data type in SQL into INT and data type in SSIS as INT32 but before I used the last option, I would like to listen to any suggestions here. Thank you.

What I have tried:

1. Change data type in SSIS from INT64 into String as suggested online and remain data type in SQL as BIGINT but did not work.

推荐答案

根据这篇MSDN博客文章 [ ^ ]从2007年起, bigint 值将作为字符串返回,因为没有跨平台支持变体中的8字节整数类型[ ^ ]值。



帖子表明这将在未来版本中修复。然而,2010年的评论称,它在2008R2中没有得到修复。另一条评论表明它在2012年也没有修复。



看起来你将不得不将SSIS参数类型更改为字符串,并尝试解决你使用这种方法遇到的问题。
According to this MSDN blog post[^] from 2007, bigint values are returned as strings, because there was no cross-platform support for an 8-byte integer type in variant[^] values.

The posts suggests that this would be fixed in a future version. However, a comment from 2010 says that it wasn't fixed in 2008R2. Another comment suggests that it wasn't fixed in 2012 either.

It looks like you're going to have to change the SSIS parameter type to string, and try to resolve the problems you had with that approach.


BigIS在SSIS中的相应数据类型是sbyte IN ssis
Bigint 's corresponding data type in SSIS is sbyte IN ssis


这篇关于分配给变量“XXXXX”的值的类型。与当前变量类型不同的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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