Home All Groups Group Topic Archive Search About

Executing a DTS package

Author
3 Feb 2006 8:17 AM
Reggie
Hi and TIA.  What I'm trying to do is create a DTS package in SQL
Server(2K).  What I then want to do is have my users locate the
database(Access2K) file, upload the file to a virtual directory, and then
fire off the DTS package to import the data from the access tables into
existing tables in SQL server.  I can't seem to find anything on how to do
this from my web app.  Is this possible and if so if you could point me in
the right direction for my research and or provide any sample basic codes
snippets as to how to accomplish this task would be greatly appreciated.
Using .net v1.1, vb.net and sql server 2000.  Thank you for your time.

--

******************
Reggie

Author
3 Feb 2006 11:16 AM
jamesb
You could have the DTS package stored as a job in Sql Server, then call
this job from a stored procedure. To call a job from inside a stored
procedure, the syntax is:

EXEC msdb.dbo.sp_start_job @job_name = 'Put your job name here'

Then just call the stored procedure as normal from your asp.net code

Hope this helps :)

James
Author
4 Feb 2006 6:37 AM
Reggie
Awesome.  I'll give it a try.  Thanks James!

--

******************
Reggie
Show quote
"jamesb" <j**@ovum.com> wrote in message
news:1138965419.571185.296990@g44g2000cwa.googlegroups.com...
>
> You could have the DTS package stored as a job in Sql Server, then call
> this job from a stored procedure. To call a job from inside a stored
> procedure, the syntax is:
>
> EXEC msdb.dbo.sp_start_job @job_name = 'Put your job name here'
>
> Then just call the stored procedure as normal from your asp.net code
>
> Hope this helps :)
>
> James
>

AddThis Social Bookmark Button