Solved

Using Java to run DTS

Posted on 2004-08-23
3
1,356 Views
Last Modified: 2013-11-30
hi,

i've a  DTS package in a  .DTS file format

Is it possible to initiate a DTS package remotely from java, maybe using JDBC?  Any examples would be greatly appreciated.
0
Comment
Question by:chee_torr
[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
3 Comments
 
LVL 13

Accepted Solution

by:
danblake earned 500 total points
ID: 11872477
You may not like this, but you would have to write the following
1) A SQL Server Job to execute the DTS File from .DTS File format using dtsrun (see BOL)
2) A Java call to the database server to run a sp_startjob @jobname on the sql-server to start the sql-job.

I do not think that you can directly call the DTS packages directly from within JDBC.

Or alternativly initiate a call to the dtsrun utility within java (a simple command prompt external execution).
DTSRun:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnsql2k/html/dts_overview.asp
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/coprompt/cp_dtsrun_95kp.asp

Java call:
http://www.experts-exchange.com/Programming/Programming_Languages/Java/Q_21064042.html
0

Featured Post

Creating Instructional Tutorials  

For Any Use & On Any Platform

Contextual Guidance at the moment of need helps your employees/users adopt software o& achieve even the most complex tasks instantly. Boost knowledge retention, software adoption & employee engagement with easy solution.

Question has a verified solution.

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

Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

688 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