Round to four decimal places in SSIS dervied column

M S Reshman Mazhoodha 26 Reputation points

I have a query ((DT_DECIMAL,2)[Coulmn1] / (DT_DECIMAL,2)[Column2]) + 0.0224. This query gives me a result 0.584900000. I need to round this to 4 decimal places. Tried giving ROUND([OutputColumn],4) but still getting the same output. How to remove those zeros and round to 4 decimal places? The expected output is 0.5849.

SQL Server Integration Services
SQL Server Integration Services
A Microsoft platform for building enterprise-level data integration and data transformations solutions.
2,496 questions
0 comments No comments
{count} votes

Accepted answer
  1. ZoeHui-MSFT 34,591 Reputation points

    Hi @M S Reshman Mazhoodha ,

    You may use below query for a try.

    (DT_DECIMAL,4)(((DT_DECIMAL,2)Coulmn1 / (DT_DECIMAL,2)Coulmn2) + 0.0224)




    If the answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.
    Hot issues October

    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. M S Reshman Mazhoodha 26 Reputation points

    @ZoeHui-MSFT conversion works fine now. But mapping is failing as it was previously DT_Numeric and now it is DT_Decimal. Should I convert as DT_Numeric again and how?

    In Union All I am not able to map those columns. I am getting the following error.