-1

Below is my ask.

  1. I have a column A in source table that has value 0 and 1.
  2. I have created a derived table for that column and associated column B, and have destination table where there is already associated column which has value "XYZ" where source column has value = 0.
  3. So if value in source table changes from 0 to 1, the destination column will have the value "ABCD", and if the value changes back from 1 to 0, the destination column should have value "EFGH". Pl

Please help me, how to do this.

Venkataraman R
  • 12,181
  • 2
  • 31
  • 58
asd
  • 1
  • 3
    Welcome to Stack Overflow. Your question doesn't include enough useful detail for us to help you. Check out [How To Ask](https://stackoverflow.com/help/how-to-ask) and the importance of a [Minimal, Complete, Verifiable Example](https://stackoverflow.com/help/mcve). After that, [Start Here](https://spaghettidba.com/2015/04/24/how-to-post-a-t-sql-question-on-a-public-forum/) to edit your question as needed. – Eric Brandt Nov 01 '18 at 18:24
  • Easiest way is to create trigger, read through Update, insert triggers – Ven Nov 02 '18 at 13:14

1 Answers1

0

You can do the below steps to do the activity.

  1. Create a data flow task in SSIS for datamovement
  2. Create a source component for extracting data from table
  3. Create a derived column transform for mapping 0 & 1 accordingly using SSIS expressions
  4. Create a update OLEDB command transform for updating the record, based on step no. 3 derived value
Venkataraman R
  • 12,181
  • 2
  • 31
  • 58