dbTalk Databases Forums  

SSIS, Lookups, and Redirect Row

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss SSIS, Lookups, and Redirect Row in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
tbmilk@gmail.com
 
Posts: n/a

Default SSIS, Lookups, and Redirect Row - 02-23-2006 , 01:53 PM






I was wondering if there was a way to further examine a redirected rows
from a lookup?

For Example:

If I have a lookup comaring two sources (Flat File against a DB Table)
and redirecting rows that do not match---Can I perform a transform that
will detect the columns and values that did not match?

I would like to store the columns of the unmatched values into a
variables and use it in a OLE DB statement.

The idea would be that I map the variables to a parameters so that I
wouldn't have to write arduous SQL statements for large tables in our
Data Repository.

For Example: (I don't want to have to write an OLE DB like this):

UPDATE <table>
SET <column1> = ?, <column2> = ?, <column3> = ?, <column4> =
?,....<column55> = ?

It would be nice to write it like this:

UPDATE <table>
SET ?* = ?**

?* = the columns identified in the lookup
?** = the values identified in the lookup

================================================== =================

I might be thinking about this whole process wrong, so any information
that might point me in the right direction would be appreciated


Reply With Quote
  #2  
Old   
Allan Mitchell
 
Posts: n/a

Default Re: SSIS, Lookups, and Redirect Row - 02-25-2006 , 02:23 PM






Hello Travis,

The rows you pipe to the error output can be used however you want. They
can essentially become another source to the pipeline. Using the OLE DB
transform then you would have to issue a statement

UPDATE <table> SET <col> = ?, <col2> = ? etc

you then map the incoming columns from the error output to the right ?

If you do not like this (row based) then stage these rows and outside of
the data flow issue a set based UPDATE in an ExecuteSQL task.



Allan Mitchell
www.SQLDTS.com
www.SQLIS.com
www.Konesans.com

Quote:
I was wondering if there was a way to further examine a redirected
rows from a lookup?

For Example:

If I have a lookup comaring two sources (Flat File against a DB Table)
and redirecting rows that do not match---Can I perform a transform
that will detect the columns and values that did not match?

I would like to store the columns of the unmatched values into a
variables and use it in a OLE DB statement.

The idea would be that I map the variables to a parameters so that I
wouldn't have to write arduous SQL statements for large tables in our
Data Repository.

For Example: (I don't want to have to write an OLE DB like this):

UPDATE <table
SET <column1> = ?, <column2> = ?, <column3> = ?, <column4> =
?,....<column55> = ?
It would be nice to write it like this:

UPDATE <table
SET ?* = ?**
?* = the columns identified in the lookup
?** = the values identified in the lookup
================================================== =================

I might be thinking about this whole process wrong, so any information
that might point me in the right direction would be appreciated




Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.