Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


How can use mapping in SSIS using Script in SSIS


How can use mapping in SSIS using Script in SSIS

Author
Message
Dicha
Dicha
Grasshopper
Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)

Group: General Forum Members
Points: 10 Visits: 21

This example i have in my DTS package..

Function Main()
DTSDestination("DATA")=YEAR(DATE) & "-" & RIGHT("0" & TRIM(CSTR(MONTH(DATE))), 2) & "-" & RIGHT("0" & TRIM(CSTR(DAY(DATE))), 2)
DTSDestination("BDNCAR") = DTSSource("BDNCAR")
DTSDestination("BDSITU") = DTSSource("BDSITU")
DTSDestination("BDMSIT") = DTSSource("BDMSIT")
DTSDestination("BDDTEM") = DTSSource("BDDTEM")
DTSDestination("BDDTEX") = DTSSource("BDDTEX")
DTSDestination("BDDTUU") = DTSSource("BDDTUU")
DTSDestination("BDDSIT") = DTSSource("BDDSIT")
DTSDestination("BDNVUS") = DTSSource("BDNVUS")
DTSDestination("BDNOM1") = DTSSource("BDNOM1")
DTSDestination("BDRCLI") = DTSSource("BDRCLI")
DTSDestination("BDNCLI") = DTSSource("BDNCLI")
DTSDestination("BDNATR") = DTSSource("BDNATR")
DTSDestination("BDNSEQ") = DTSSource("BDNSEQ")
DTSDestination("BDRCAR") = DTSSource("BDRCAR")
DTSDestination("BDMOED") = DTSSource("BDMOED")
DTSDestination("BDTANU") = DTSSource("BDTANU")
DTSDestination("BDANUI") = DTSSource("BDANUI")
DTSDestination("BDTEMI") = DTSSource("BDTEMI")
DTSDestination("BDCCAS") = DTSSource("BDCCAS")
DTSDestination("CMBDCLCP") = DTSSource("CMBDCLCP")
DTSDestination("BDCPRD") = DTSSource("BDCPRD")
DTSDestination("BDCCPR") = DTSSource("BDCCPR")
Main = DTSTransformStat_OK
End Function

I have to change and remake this package(dts) using SSIS package..pLease can any one tel me how can i solve this problem.

how can i create this kind of mapping in my SSIS project??

thank you dilsa


Tim Mitchell
Tim Mitchell
Ten Centuries
Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)

Group: General Forum Members
Points: 1134 Visits: 2915

Dilsa,

It looks like this is a fairly simple mapping, with only the first value requiring any manipulation before going to the destination. I would use a Derived Column task to send the new value you call "DATA" to the destination. You don't need to script this kind of task in SSIS.

hth
Tim





Tim Mitchell, Microsoft Data Platform MVP
Data Warehouse and ETL Consultant
TimMitchell.net | @Tim_Mitchell | Tyleris.com
ETL Best Practices


mp83399
mp83399
Forum Newbie
Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)

Group: General Forum Members
Points: 4 Visits: 3
Yes very true......
This seems to be a like a very simple mapping. Just create a DataFlow task. Define a source and a destination and have a derived col transform in between. On the dest connection, map based on the specs you have in the old DTS package.
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search