I have the two tables which need to be linked and present the data in human friendly way. Could you experts point me in right direction, I am bit stuck here.
Both table 1 and table2 are received through ftp and loaded to SQL table in SQL 2008 R2. These two tables are linked by nid
and cid
together.
Apologies i couldn't copy paste table here, please consider "-" are column separators
Table 1
ID nid cid pid form_key-name 1 4 1 33 Import_Gen_Title-Title 2 4 2 33 Import_Gen_Firstname-Firstname 3 4 3 33 Import_Gen_Surname-Surname 4 4 4 33 Import_Gen_AddressLine1-AddressLine1 5 4 5 33 Import_Gen_AddressLine2-AddressLine2 6 4 6 33 Import_Gen_City-Town/City 7 4 7 33 Import_Gen_Zip-Post code
Table 2
ID nid sid cid data 1 4 14 1 Mr 2 4 14 2 John 3 4 14 3 Smith 4 4 14 4 A Company 5 4 14 5 Nice Street 6 4 14 6 London 7 4 14 7 SE11 0TS
Now how can get this a Result Table like this one below ?
NiD SID Title Firstname Surname AddressLine1 AddressLine2 Town/City-Post code 4 14 Mr John Smith A Company Nice Street London-SE11 0TS