Question: I am tansfering data from MSSQL to MySQL using SSIS.I have done mapping of all the tables.But while executing the package I am getting errors :

> 
> [tabl\_name [1056]] Error: An exception has occurred during data insertion, the message returned from the provider is: ERROR [07006] [MySQL][ODBC 3.51 Driver][mysqld-5.1.33-community-log]Restricted data type attribute violation(SQL\_C\_NUMERIC)
> 
> 
> [product [402]] Error: An exception has occurred during data insertion, the message returned from the provider is: Unable to cast object of type 'System.Int32' to type 'System.Char[]'.
> 
> 
> 

I also compared the data type of all the columns and I found it same.
After that I did some research and found there is problem with data type decimal(10,2).But I dint find the solution.

Thanks in advance.

Answer: 
One simple way to get out of this kind of problem is to temporary convert that problematic column from decimal to varchar, after complete the migration, convert it back to decimal.

The above can apply to MSSQL since the error is complained at MSSQL.
Either use a data conversion in the data flow task or cast your invalid types in the source query. 

```

DECLARE @bit as bit
set @bit = 1
SELECT CAST(@bit as int)

```