August 22, 2005 at 3:43 am
Hi!
I try to run a DTS from an simple ASP page. The package is just a simple test, and it works fine from Enterprise Manager. But not from ASP.
Im using NT authentication and I've given the IUSR administrator rights in this testing environment (all possible rights) just to test thats not an security issue, but maybe it is? I've checked out all forums i could find but none seemed to solve this.
Note: I don't want to use XP_CMDSHELL (the dtsrun command) - that works fine, but I want to have more realtime control of the output, speed is not an issue.
Thanks in advance!
I get the following error:
Step [DTSStep_DTSDataPumpTask_1] failed
Task "testing"
Package [testpackage] failed
Here is the source code:
<%
Const DTSSQLStgFlag_Default = 0
Const DTSStepExecResult_Failure = 1
Dim oPkg, oStep, sMessage, bStatus
Set oPkg = Server.CreateObject("DTS.Package")
oPkg.LoadFromSQLServer "(local)","","",256,"","{43CA3427-4958-4A75-B648-8288106D5A55}","{6643E36D-D9BC-42D7-93B7-2FCE0173F875}","testing"
oPkg.Execute()
bStatus = True
For Each oStep In oPkg.Steps
sMessage = sMessage & "<p> Step [" & oStep.Name & "] "
If oStep.ExecutionResult = DTSStepExecResult_Failure Then
sMessage = sMessage & " failed<br>"
bStatus = False
Else
sMessage = sMessage & " succeeded<br>"
End If
sMessage = sMessage & "Task """ & oPkg.Tasks(oStep.TaskName).Description & """</p>"
Next
If bStatus Then
sMessage = sMessage & "<p>Package [" & oPkg.Name & "] succeeded</p>"
Else
sMessage = sMessage & "<p>Package [" & oPkg.Name & "] failed</p>"
End If
Response.Write sMessage
Response.Write "<p>Done</p>"
%>
August 22, 2005 at 6:30 am
Do not cross-post, finish the discussion here :
http://www.sqlservercentral.com/forums/shwmessage.aspx?forumid=92&messageid=212472
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply