Quantcast
Channel: SQL Server Integration Services forum
Viewing all articles
Browse latest Browse all 24688

SSIS read the data from table and insert 2 rows in another table

$
0
0

Hello,

I am new to ssis and i have a requirement to read the data rows from one source table and insert tow different rows in another table

Reading the rows and inserting is working fine using data flow in SSIS

But I have to insert the source rows(split source and insert into 2 rows in destination) based on Common ID

i.e Source System ID and Source System Key in one row and targetSystemID and Target system key in another row with same commonID,RefID

example

Source table columns & Rows

RefID      SourceSystemID    SourceKey               TargetSystemID     TargetKey               CommonID   CommonKeyDate

3              1                        9BFG06E8AD              2                       001351913001         12345         20-02-2010 09:11:43

4              1                        8KIJ67ASG9               2                       002352014005         45678         20-02-2010 09:11:43

Required Destination Column Rows

DataID(AutoIncrement)    RefID      SystemID          SystemKey            CommonID            DateCreated(using getdate())

 

1                                     3             1                      9BFG06E8AD        12345                    getdate()   

2                                     3             2                      001351913001     12345                    getdate()

3                                     4             1                      8KIJ67ASG9          45678                    getdate()

4                                     4             2                      002352014005     45678                    getdate()

                                 

Can anyone assist , please?

thanks


Sri


Viewing all articles
Browse latest Browse all 24688


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>