Solved

SP to run DTS's

Posted on 2012-04-05
2
268 Views
Last Modified: 2012-04-16
Team -

I have 5 DTS packages which i am running to upload 5 different csv files to 5 different tables. This is a routine process which i need to run everyday.

can someone help me to write an SP where i call all the 5 dts's pls. so i just have to run 1 SP instead of 5 different dts
0
Comment
Question by:davidi1
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 29

Accepted Solution

by:
QPR earned 500 total points
ID: 37815262
this requires using  xp_cmdshell.
If you'd prefer not to do this then set up a SQL "job" for the DTS package and then run the job from within your SP by using sp_start_job
Use this for each job you want to start.

http://msdn.microsoft.com/en-us/library/ms186757(v=sql.90).aspx
0
 
LVL 25

Expert Comment

by:jogos
ID: 37815295
How to run dts from sql
http://www.sql-server-performance.com/forum/threads/how-to-run-dts-from-t-sql.19155/

But mind on how to handle errors.

Which sql version? You can also make one SSIS package which handles the 5 files.
http://msdn.microsoft.com/en-us/library/ms141026(v=sql.100).aspx
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

JSON is being used more and more, besides XML, and you surely wanted to parse the data out into SQL instead of doing it in some Javascript. The below function in SQL Server can do the job for you, returning a quick table with the parsed data.
A Stored Procedure in Microsoft SQL Server is a powerful feature that it can be used to execute the Data Manipulation Language (DML) or Data Definition Language (DDL). Depending on business requirements, a single Stored Procedure can return differe…
Via a live example, show how to setup several different housekeeping processes for a SQL Server.
Viewers will learn how the fundamental information of how to create a table.

631 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