all groups > sql server dts > april 2007 >
You're in the

sql server dts

group:

Destination column value from Global variable


Destination column value from Global variable mkhan2001 NO[at]SPAM gmail.com
4/9/2007 9:13:37 PM
sql server dts:
Hi,

I am learning SSIS and trying to create a DTS package for importing
data from Excel Source to OLE DB Destination. It works fine if I have
all columns in the Excel Source match exactly with columns in D/B
table. But I have few columns in the D/B table, Fkey ids which are not
available in the Excel Source. These column values are stored as
Global Variables. I would like to import these values of Global
variables in addition to the columns from Excel Source to D/B table.

For example
Excel source FirstName, LastName

DatabaseTable Id, FirstName, LastName, FKID1

Global Variable v1= FKID1

This import should fill FKID1 from the Global variable v1.(same value
for all the rows imported)


Any help is appreciated.

Thanks
Re: Destination column value from Global variable Allan Mitchell
4/10/2007 8:16:44 PM
Hello mkhan2001@gmail.com,

Add a Derivd Column Transform after the Source Adapter and Before the Destination
Adapter. Create a New Column and as the Expression you will use the Variable.

Make sense?

--

Allan Mitchell
http://wiki.sqlis.com | http://www.sqlis.com | http://www.sqldts.com |
http://www.konesans.com

[quoted text, click to view]

AddThis Social Bookmark Button