dbTalk Databases Forums  

DTSTaskExecResult_Success

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


Discuss DTSTaskExecResult_Success in the microsoft.public.sqlserver.dts forum.



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

Default DTSTaskExecResult_Success - 05-19-2005 , 04:54 PM






i am executing

Following

DECLARE @res int
EXEC @res=Exec Admin_Fixes_Process_Duplicates_Referrals
SELECT @res

in Execute SQL Task

My question, If @res value is not equal to 0 i have to make
task failure else goto next task

can any one give idea how to solve my problem,




Reply With Quote
  #2  
Old   
Rodney Mullins
 
Posts: n/a

Default RE: DTSTaskExecResult_Success - 05-19-2005 , 06:09 PM






Kalyan,


SELECT @res into a column alias.. For example

SELECT @res as ResultCode

Next, click on the parameter button. Click on the Output Parameter tab
followed by the Row Value and you should see ResultCode. From there you can
assign the ResultCode to a Global Variable. Next using ActiveX Script , you
can read in the global variable and set the Workflow Success or Failure flag
based on the value in the REsultCode.
"Kalyan" wrote:

Quote:
i am executing

Following

DECLARE @res int
EXEC @res=Exec Admin_Fixes_Process_Duplicates_Referrals
SELECT @res

in Execute SQL Task

My question, If @res value is not equal to 0 i have to make
task failure else goto next task

can any one give idea how to solve my problem,




Reply With Quote
  #3  
Old   
Darren Green
 
Posts: n/a

Default Re: DTSTaskExecResult_Success - 05-19-2005 , 06:21 PM



Or maybe fail the task with raiserror?

if @res <> 0
raiserror(blah blah)


In message <1803284C-D1C8-40C9-90A1-38AF5BEA0973 (AT) microsoft (DOT) com>, Rodney
Mullins <Rodney (AT) Mullins (DOT) ?.microsoft.com.invalid> writes
Quote:
Kalyan,


SELECT @res into a column alias.. For example

SELECT @res as ResultCode

Next, click on the parameter button. Click on the Output Parameter tab
followed by the Row Value and you should see ResultCode. From there you can
assign the ResultCode to a Global Variable. Next using ActiveX Script , you
can read in the global variable and set the Workflow Success or Failure flag
based on the value in the REsultCode.
"Kalyan" wrote:

i am executing

Following

DECLARE @res int
EXEC @res=Exec Admin_Fixes_Process_Duplicates_Referrals
SELECT @res

in Execute SQL Task

My question, If @res value is not equal to 0 i have to make
task failure else goto next task

can any one give idea how to solve my problem,



--
Darren Green (SQL Server MVP)
DTS - http://www.sqldts.com

PASS - the definitive, global community for SQL Server professionals
http://www.sqlpass.org



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.