import data into sql table from another table using ssis packages
hi... all. i've created one package using ssis .. That is used for transferring the data from the tableA to tableB daily at evening.. now my problem is .. i've huge amount of data i.e upto 2GB of data while transferring for first time the whole amount data is transferred.. and now i want to transfer only the daily updates i.e what data i've entered today that much only it should transfer instead of whole data (2GB).. how to do it .. please help me..
December 27th, 2010 2:26am

Do you have a field like INSERTDATE which stored date of insertion in tableA? and do you always insert data? or you may delete and update them? by the first question, if you have an INSERTDate field, so you can specify date in your sql source query in where condition. but if you have not InsertDate or if you have Update and Deletes also in tableA, you should use Lookup transform to lookup values in tableB, if you find them then update, if you didn't find then Insert. http://www.rad.pasfu.com
Free Windows Admin Tool Kit Click here and download it now
December 27th, 2010 3:02am

Vinayak, You can use Lookup/Merge Join Comonent with OLE DB Command transformation to complete your task. Use Lookup/Merge Join -- to find New records or existing records.. IF the Records are new use OLE DB to perform Insert operation else perform update. Refer this --http://www.sqlservercentral.com/Forums/Topic469743-148-1.aspx#bm469756 -- Sathish
December 27th, 2010 4:48am

Hi, There is another similar thread you can also refer to: http://social.msdn.microsoft.com/Forums/en/sqlintegrationservices/thread/3b1f8866-88ce-4bf8-826c-2a35d9a11ba0 Hope this helps, Raymond Raymond Li - MSFT
Free Windows Admin Tool Kit Click here and download it now
December 28th, 2010 4:24am

hi, vinayak, you can use something like max(day_idx) which gives you the maximum date from the Table B... you can then have a script task in your package which compares the date in table B with table A so that your problem might solve........ Day_IDX 10-12-2010 11-12-2010 12-12-2010 13-12-2010 14-12-2010 you have loaded up to 13-12-2010 data in table B and table b has day_idx as follows Day_IDX 10-12-2010 11-12-2010 12-12-2010 13-12-2010 now you want to load 14th data from table A to table B...you can query using execute sql task and find max(day_idx) from table b you get 13-12-2010 as result store it in a variable and using script task put some condition which compares date of table A with table B some like this if(day_idx_a == dat_idx_b +1 )...if it satisfies then load your data....try this one i think this will help you thanks, latheesh
December 28th, 2010 5:22am

hi, vinayak, you can use something like max(day_idx) which gives you the maximum date from the Table B... you can then have a script task in your package which compares the date in table B with table A so that your problem might solve........ Day_IDX 10-12-2010 11-12-2010 12-12-2010 13-12-2010 14-12-2010 you have loaded up to 13-12-2010 data in table B and table b has day_idx as follows Day_IDX 10-12-2010 11-12-2010 12-12-2010 13-12-2010 now you want to load 14th data from table A to table B...you can query using execute sql task and find max(day_idx) from table b you get 13-12-2010 as result store it in a variable and using script task put some condition which compares date of table A with table B some like this if(day_idx_a == dat_idx_b +1 )...if it satisfies then load your data....try this one i think this will help you thanks, latheesh
Free Windows Admin Tool Kit Click here and download it now
December 28th, 2010 5:22am

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

Other recent topics Other recent topics