Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Import/Export (DTS) and Replication (2000)
 how do you halt a DTS without failing it ?

Author  Topic 

css_jay99
Starting Member

9 Posts

Posted - 2006-06-12 : 05:27:02
Hi, I have a DTS package that dynamically builds a query with ActiveX and then passes the whole query to Oracle to retrieve information.
It does a few other things as well down the line but activex part is only at step two while there are about 8 other steps

the query ends up into something like
SELECT x, y, z
FROM table
WHERE q IN
(1,2,3,4,5)


There are times when the conditions are not match an the query ends uop into something like

SELECT x, y, z
FROM table
WHERE q IN
()


In the immediate case above this causes a failure on oracle cos its an incomplete statement


What I would like to do in such cases is to:-
at step 2, if the where clause = "()", fail the package.

When i say fail the package I just mean dont bother executing the rest of the steps and still end up with a status that the package ran successfully ?


I presume this will be done in the activex part


Urgent reply needed

Thanks


css_jay99

by the way I am new to DTS, activex ...

css_jay99
Starting Member

9 Posts

Posted - 2006-06-12 : 10:08:36
help ?
Go to Top of Page

Wanderer
Master Smack Fu Yak Hacker

1168 Posts

Posted - 2006-06-12 : 10:37:16
Basically, you're looking for an SQL statement parser. Is there a way to invoke a SQL validation, and not execution? If you can find that, then on SUCCESS you can execute, and on FAILURE you FAIL. I don't know if such a thing exists, however - good luck with it...

*##* *##* *##* *##*

Chaos, Disorder and Panic ... my work is done here!
Go to Top of Page

css_jay99
Starting Member

9 Posts

Posted - 2006-06-12 : 11:07:37
Hi I am not actually looking for a parser,
I am just looking for a way of stopping a DTS package without reporting it a a Failure.


to clarify further, if I have a DTS with 5 steps all to succeed after the other
i.e 1->2->3->4->5

if step 2 in activex task, I want to halt/stop execution of the remaining steps without failing the package. Sort of like jumping to the end in a program code. Does that make send?

cheers
Go to Top of Page

jen
Master Smack Fu Yak Hacker

4110 Posts

Posted - 2006-06-12 : 22:17:58
use workflow to control how the steps/tasks

--------------------
keeping it simple...
Go to Top of Page
   

- Advertisement -