I am using an Azure Data Factory to get data from an on prem database to an Azure sql database.
I am doing it in 2 steps:
- Copy to blob
- Insert into azure using a copy activity that runs a stored procedure.
The problem i have is the decimal is rounded up and the destination values are different than source.
For the entire process i have defined 3 datasets:
- SQLDataset - the structure node is {... "name" : "MyColumn", "type":"Decimal"}.
- BlobDataset - the structure node is the same as above
- AzureSQLDataset - the structure node is the same
On the SQL database, i have a user defined table type as follows:
CREATE TYPE dbo.myType TABLE (...MyColumn decimal(28,10) null)
The stored procedure does an insert or an update and no data transformation. However, when i query for MyColumn value, the values end up being rounded up.
If source had a value of 266222451894.019990000 , target has a value of 266222451894.0200000000
Am i missing something ?