![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I'm using DTS in SQL Server 2000. This is the first time I've used it extensively. I have a task which is trying to "manually" roll back a set of steps if any errors have occurred in a previous step. In the Execution Progress dialog, the previous step shows up with "Errors occurred (nnn)". Yet, Step.ExecutionStatus is 4 and Step.ExecutionResult is zero! This leads to several questions: 1) What is it which is displaying in that Status column, and can I access it programattically? 2) The transformation which is causing the errors is returning DTSTransformStat_ExceptionRow. Should it be returning some other value in order to log the row in error and have the error counted as an error? I would ideally like to be able to use an On Failure workflow to go to the step which will handle the errors. 3) I noticed that the corresponding task has RowsInError <> 0. Should I be looking at the Task instead of the Step? I'll eventually learn how to use transactions with DTS and this won't be necessary when that happens. But in the meantime, I could really use some help with this. Thanks, John Saunders |
#3
| |||
| |||
|
|
The execution dialog is no doubt driven by the execution events. The error event would seem most interesting here. |
|
It does sound a bit strange that the result is success. Odes on failure workflow do the job? |
|
Sometimes the state of a value at execution time, or a stage of execution can differ from what you see and expect afterwards or just later on. The step handles timings and status information. This stuff is common to all tasks. The task wraps the custom task, and it is that which provides the function specific stuff, such as RowsInError. So use the correct object for what you need. |
#4
| |||
| |||
|
|
Thanks, Darren, the distinction makes sense now. Can one reach the Task from the Step object, or vice-versa? |
#5
| |||
| |||
|
|
Also, thinking in terms of encapsulation, can a step determine it's predecessor(s) in terms of workflows? It would be good if an error-processing step didn't need to know the name of the preceding step or task, so that it could be reused. |
#6
| |||
| |||
|
|
Also, thinking in terms of encapsulation, can a step determine it's predecessor(s) in terms of workflows? It would be good if an error-processing step didn't need to know the name of the preceding step or task, so that it could be reused. |
![]() |
| Thread Tools | |
| Display Modes | |
| |