Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Lookup transformation [Lookup Data Key [95]] Error: Row yielded no match during lookup Expand / Collapse
Author
Message
Posted Sunday, November 29, 2009 5:02 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Sunday, August 25, 2013 2:49 PM
Points: 34, Visits: 100
Hello All,
I am using SSIS to import data from one datasource to another data destination.
I have following scenerio
I have two servers [server1] and [server2]
I have to transfer employee records only on the basis of Departments available in Server2's table(i.e. tbl_Department)

In technical terms
I have to implement following query
SELECT * FROM server1..tbl_EMPLOYEE WHERE DEPARTMENT IN (SELECT DEPARTMENT_Name FROM server2..TBL_DEPARTMENT).

I tried using lookup transformation but got following error
[Lookup Data Key [95]] Error: Row yielded no match during lookup

Please guide me the best way to do this.

Please do help...whatever you can...really appreciate you all. Advance Thank You all.

Post #825869
Posted Monday, November 30, 2009 10:14 AM
SSChasing Mays

SSChasing MaysSSChasing MaysSSChasing MaysSSChasing MaysSSChasing MaysSSChasing MaysSSChasing MaysSSChasing Mays

Group: General Forum Members
Last Login: Friday, August 31, 2012 10:31 AM
Points: 633, Visits: 1,695
The first question you need to answer is what to do with records that don't have a matching Department in your TBL_DEPARTMENT table. Can you ignore those records, or do you need to report them at some point?

In the Reference Table table of the Lookup Transformation Editor, you should select Use Results of a SQL query and enter "SELECT DEPARTMENT_Name FROM server2..TBL_DEPARTMENT." On the Columns tab, join the DEPARTMENT field of the Available Input Columns to the DEPARTMENT_NAME field of the Available Lookup Columns.

Click on the Configure Error Output button. Go to the Error column of the Lookup Output row. To ignore unmatched records, select Ignore Failure from the drop-down. To enable the ability to redirect the unmatched rows to another output, select Redirect Row.
Post #826341
Posted Monday, November 30, 2009 11:39 PM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Sunday, August 25, 2013 2:49 PM
Points: 34, Visits: 100
Its working fine after applying Ignore failure.

Thank you so much for the help.
Post #826498
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse