Parent-Child Table Population Help
Hi, I have three tables Contact, Address and Address_Type. The Contact Table and Address Table are Parent Tables and Address Type table is a child table. The Contact Table : CID First Name LastName 101 John Mathew 102 John Mathew Adress Table : ID Address 1 201 Green Arbor 202 Blue Arbor Address Type Table Address TyPE ID CID(FK) ID(FK) 301 101 201 302 102 202 I am successfully able to load my Parent Tables : ( Contact ) and Address ....but there is a problem when I try to load the child table. How do I select in the lookup so that it gives me both the CIDS related to IDS in the Address Table. At present I am only able to pick one key 101 or 102 .....since I have two different people with the same name. In the lookup I only pick comparing the matching firstname and lastname. Please advice. Thanks, eva 201 EVA05
January 26th, 2011 9:35pm

What do you mean load? Load from where? Seems like you could do a conditional split then merge join, but I am unsure at the moment. Also I guess it is possible to do that using the pure T-SQL.Arthur My Blog
Free Windows Admin Tool Kit Click here and download it now
January 26th, 2011 11:51pm

What do you mean load? Load from where? Seems like you could do a conditional split then merge join, but I am unsure at the moment. Also I guess it is possible to do that using the pure T-SQL.Arthur My Blog
January 26th, 2011 11:51pm

There should be a relation between your CONTACTS table and ADDRESSES Table, such as CONTACTS should have ADDR_ID or ADDRESSES Should have CONTACT_ID.....then basically you just join them on a Unique key and Migrate into ADDRESS_TYPE.....Is there any relation between ADDRESSES and CONTACTS table.....if not i would suggest create it.. Is there a CUSTOMER_ID in any of those tabless....
Free Windows Admin Tool Kit Click here and download it now
January 27th, 2011 1:19am

Eva, I'm not 100 percent sure about what you need, but from what you've written here I guess you have matched the columns in your lookup transformation so that it only compares CIDs to determine weather a new row should be added to the destination table or not. What you should do is to configure your lookup table, and match both CID(Customer tables's PK) and ID(Address table's PK). If I am wrong about what you need at this stage, please make your problem and requirement more clear.http://thebipalace.wordpress.com/
January 27th, 2011 2:49am

Eva, I'm not 100 percent sure about what you need, but from what you've written here I guess you have matched the columns in your lookup transformation so that it only compares CIDs to determine weather a new row should be added to the destination table or not. What you should do is to configure your lookup table, and match both CID(Customer tables's PK) and ID(Address table's PK). If I am wrong about what you need at this stage, please make your problem and requirement more clear.http://thebipalace.wordpress.com/
Free Windows Admin Tool Kit Click here and download it now
January 27th, 2011 2:49am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics