SSIS Package Copy/Paste New GUID (ID) Fix
Posted by denglishbi on March 25, 2011
When doing development with Integration Services (SSIS) in Business Intelligence Development Studio (BIDS) it is quite common to copy an existing SSIS package to begin work on a new one. This could be because you have a package template that you are using in your environment or possibly just to back up your package because you want to make a modification and are not using a source control system (definitely not a best practice to not be using a source control system).
The one thing you need to be aware of at least when performing a copy/paste of an existing package in BIDS 2005 and 2008 is that each package is setup with a unique identifier known as a GUID.
When you copy and paste the existing package to begin working on a new version of the package the cloned version of the package will keep all of the same values of the template copy of the package.
This can become very problematic when you have SSIS logging enabled and are trying to troubleshoot a package and all of your packages have the same GUID value assigned to them. So in BIDS 2005 and 2008 the way to get around this problem was to use the drop-down list in the ID property to generate a new ID (GUID) value to the copied (cloned) version of the master package.
NOTE: Doing this only assigns a new ID (GUID) value to the package. All of the other items in the package will all still have the same ID values as the template package
The other option you have in changing the ID values is to leverage the BIDSHelper add-in that is available on CodePlex. I had forgotten about this option and a special thanks goes out to Bhavik Merchant (Blog | Twitter) for reminding me about this through Twitter land yesterday.
The nice thing about doing this with the BIDSHelper add-in is that it will not only assign the package a new ID value, but also all of the other items within the package!
This is a great feature because if you have the setup like I did above with a Data Flow Task and are going to use Data Viewers you might have run into this issue before – SSIS package copy paste data flow task (dft) data viewer issue. This bug is in BIDS 2005 and 2008 (has been fixed in 2008 R2 though). When you add a Data Viewer into your cloned package and then go back to your template package you will see that the Data Viewer exists in both! Wow, what a cool feature and it really freaks you out when you run your cloned package and get all of these popups, especially if you have 10 or 15 cloned packages in a single project. Really neat, NOT.
Cloned Package 2
But if you are using the BIDSHelper add-in this would resolve the issue because it assigns new ID values to all of the items, so this would not be an issue.
Cloned Package 1
Lets fast forward now into BIDS 2008 R2. If you copy and paste a package in BIDS 2008 R2 the new package automatically gets assigned a new ID (GUID) value. So the issue of having multiple packages with the same ID values has been resolved out-of-the-box with no additional actions required by the developer. A nice little feature that I experienced yesterday and noticed. I had still been using the generate new ID option without even realizing the copied package already had a new ID value.
BIDS 2008 R2
The trick is that you have to actually rename the package and it will assign a new ID value to the copied package.
This doesn’t assign new values to the other items, but the issue that you experience with the Data Flow Task and Data Viewers is fixed in BIDS 2008 R2.
So with BIDS 2008 R2 you get new ID values for each copied SSIS package and the issue with using Data Viewers in copied Data Flow Tasks has been fixed as well. You might still want to leverage the functionality of the BIDSHelper though to assign all items in the package a new GUID (ID) value.
Pretty cool and I didn’t even realize this was updated in BIDS 2008 R2.
UPDATE (4/11/2011): Acutally realized that this is fixed in BIDS 2008 as well. The reason I didn’t notice it before is that because you need to actually rename the package file after the copy/paste. Once you do this it will provide the package a new GUID (ID) value.