dbTalk Databases Forums  

Is this possible with DTS?

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss Is this possible with DTS? in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Chris
 
Posts: n/a

Default Is this possible with DTS? - 07-11-2006 , 08:52 PM






Hi,
I am able to execute a DTS package from a stored procedure just fine using
the login credentials from SQL Server. How can I, in the stored procedure,
change the identity to that of a WINDOWS LOGIN TO EXECUTE THE DTS PACKAGE?.
You see, I am using the MSMQ in DTS, but, my queue is on a remote server and
when I execute the package using the SQL login I get the "Access Denied"
error. The sp is executed by a trigger.

Please advice.

Reply With Quote
  #2  
Old   
Frans van Bree
 
Posts: n/a

Default RE: Is this possible with DTS? - 07-13-2006 , 06:36 AM






One possibility is calling the dtsrun.exe application via the "runas"
command. Unfortunately, this command always prompts for the Windows password,
it cannot be scripted. One solution is to use the DOS application "lsrunas".
Use dynamic sql and a call-out to the DOS shell (e.g. exec
xp_cmdshell('lsrunas ... dtsrun... <package>'). Something like that.

Search for it on Google, it is a little hard to find. It does the same, but
the password can be supplied via a parameter.

Two things: 1) hardcoding a windows password is not recommended. 2) You have
to be able to put the lsrunas.exe program somewhere on disk.

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.