Reputation: 63
I'm working on a package in SSIS to populate a table after some joining and sorting processes.
I've created a Derived Column in Visual Studio to assign 0 to any null value in a column named fraud_flag using the following expression:
ISNULL(FRAUD_FLAG)?0:FRAUD_FLAG.
The package execution works fine when I run it within the Visual Studio and the destination table is properly populated. However, the table is populated with null values whenever I run the package in SQL Server. The values are set to null for the fraud_flag column even when the sources are not null.
Upvotes: 1
Views: 199
Reputation: 2544
You can also try using REPLACENULL() function:
REPLACENULL([fraud_flag],0)
and make sure that you are mapping the derived column to the destination
Upvotes: 1