Solved

Editing a saved SQL SSIS (.dtx) package

Posted on 2009-07-08
4
1,223 Views
Last Modified: 2013-11-30
Hi

I have set up a pretty long-winded SSIS package in SQL Server to import some data from a flat file in to a SQL table. I saved the SSIS in the file system  and have the .dtx file, which enables me to run it whenever necessary. However, one of the parameters in the package needs to be amended - it's a database name in a connection string that needs altering. I can open the .dtx file with the Execute utility and can apparently edit the destination connection under the Connection Managers menu. Unfortunately this doesn't seem to take effect - and when I close the utility, the change isn't saved.

Is there a way I can edit this saved SSIS package - to avoid me needing to go through the entire process of creating a new one, just for the sake of one tiny amendment?

Thanks
0
Comment
Question by:beverleydunster
4 Comments
 
LVL 11

Accepted Solution

by:
dodge20 earned 500 total points
ID: 24804108
Do you have either bids or management studio installed? You can edit the dtsx file with either of those programs.
0
 
LVL 7

Expert Comment

by:stelth240
ID: 24804137
Package configurations are usually a good way to update properties within Connection Managers, but since your package is all created and working, it's probably easier to use variables.  You can create an expression on the Connection Manager that you need to change, and set the connection string property to the same string that's in the current property.  Then just insert the variable where you need it to be added:

"Data Source=ServerAddress;Intial Catalog=" + @[User::DatabaseName] + ";Trusted_Connection=True;"

Then you would add the variable to the execution of the package.  If you're using DTEXEC, it would be:

dtexec /f MyPackage.dtsx /SET \package.variables[DatabaseName].Value;MyDatabase

If you're using the Execute Utility, you can add the information under the Set Values page.  you would specify \package.variables[DatabaseName] as the Property Path and MyDatabase as the Value.

I would think the Connection Managers page would do what you're referring to but I'm not sure why it isn't working for you.  I'm assuming you made sure the connection you wanted to change was checked and the string was modified.
0
 
LVL 22

Expert Comment

by:PedroCGD
ID: 24804140
If you dont want to edit the package directly you can use dtexec Utility.
http://msdn.microsoft.com/en-us/library/ms162810.aspx

Helped?
Regards,
Pedro
0
 

Author Closing Comment

by:beverleydunster
ID: 31601084
I have noticed you can open the dtsx file with Management Studio and edit all the properties of it in the designer.
0

Featured Post

Best Practices: Disaster Recovery Testing

Besides backup, any IT division should have a disaster recovery plan. You will find a few tips below relating to the development of such a plan and to what issues one should pay special attention in the course of backup planning.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction In my previous article (http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/SSIS/A_9150-Loading-XML-Using-SSIS.html) I showed you how the XML Source component can be used to load XML files into a SQL Server database, us…
In this article we will get to know that how can we recover deleted data if it happens accidently. We really can recover deleted rows if we know the time when data is deleted by using the transaction log.
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

919 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now