SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2008 Forums
 SSIS and Import/Export (2008)
 SSIS Package with(Derived Column & Lookup)
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

lemondash
Posting Yak Master

United Kingdom
159 Posts

Posted - 09/27/2012 :  06:20:17  Show Profile  Click to see lemondash's MSN Messenger address  Reply with Quote
Hi All,

I have a SSIS package that has data in a table. I have a OLE DB Source to connect to the table but i need to do a look up to populate a field within that table. But the field i'm looking up on the destination is nvarchar and the source field is an int and the SSIS componet for look up dosen't allow lookup's with different data types. Can i change this with a derved column ?

I could change the the data types on the tables but their both populated form external sources.

Thank you in advance.

visakh16
Very Important crosS Applying yaK Herder

India
52309 Posts

Posted - 09/27/2012 :  10:34:59  Show Profile  Reply with Quote
Instead of simply pointing to table in lookup task you can use a query as source and in query you can do cast

ie like

SELECT othercolumn,CAST(yourlookupcolumn AS int) AS Lookupcolumn
FROM destination

then link between source and destination columns

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.07 seconds. Powered By: Snitz Forums 2000