Sunday, February 19, 2012

Getting error in Execute SQL Task

Hi,

I am trying to execute a Stored Procedure using an Execute SQL Task. my stored proc contains various input paramaters. And the datatype for some of the paramaters are numeric (decimal). So when I am passing values to those paramaters using Exec SQL Task, I have used variables of type Object as it is not working properly even if I declare the variable type as "double". So I have used Object datatype for those variables and it worked properly.

But suddenly from yesterday onwards I am getting an error message (find below).

[Execute SQL Task] Error: Executing the query "USP_InsertData" failed with the following error: "Failed to convert parameter value from a Object to a Double.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.

If any one have idea on this, please let me know to rectify this error.

Thanks in advance.

Regards,

Prakash Srinivasan

What's the value that it is trying to convert?

-Jamie

|||

Hi Jamie,

Such a fast reply it is. I am taking numeric value from table and passing that value through an SSIS's Object datatype variable to my stored proc. The datatype of the parameter in my stored proc is numeric(10,2).

Regards,

Prakash Srinivasan.

|||

Yes, but what is the actual value it is failing on? I woudl suggest that if works some of teh time then there are particular values that it doesn't like. Admittedly that seems a very strange thing to happen.

-Jamie

No comments:

Post a Comment