Question : SSIS Package Called from a SQL Job does not report error

I am executing a SSIS package with the following command in a job step in SQL 2008...

EXEC xp_cmdshell 'dtexec /f "D:\dev\DWProjects\VisionDW_CostETL\CostETL-1\MasterFlow.dtsx"'

There is a step in the package that is getting called that clearly fails and you can see the output (I have pasted the end of the output in the Code block below)  "The package execution returned DTSER_FAILURE (1)."

HOWEVER, the SQL Job reports success.  Is there anyway to force the job to fail?

I have searched high and low for what I expected to be an easy problem to solve, but have found nothing.  Help!  Thanks.
Code Snippet:
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
Progress: 2009-10-29 16:30:02.00
   Source: Execute T-SQL Statement Task 
   Executing query "USE VisionDataWH
".: 50% complete
End Progress
Error: 2009-10-29 16:30:02.01
   Code: 0xC002F210
   Source: Execute T-SQL Statement Task Execute SQL Task
   Description: Executing the query "
exec spCostAllocationMaster" failed with the following error: "There was an error processing the allocation job
 
 
 
BEGIN spCostAllocationMaster at: 2009-10-29 16:30:01.993
 
OLE DB provider "SQLNCLI10" for linked server "SQLSL1" returned message "Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.".
The OLE DB provider "SQLNCLI10" for linked server "SQLSL1" could not INSERT INTO table "[SQLSL1].[Vision_Prod].[dbo].[tEventLog]" because of column "sEventDesc". The data value violated the integrity constraints for the column.". Possible failure reasons:
 Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.
End Error
DTExec: The package execution returned DTSER_FAILURE (1).
Started:  4:30:01 PM
Finished: 4:30:02 PM
Elapsed:  0.874 seconds
(null)

Answer : SSIS Package Called from a SQL Job does not report error

I understand - but as for the sql agent the step succeeds - it can execute the dtexec...

Have you tried to put the SSIS job into msdb and then create a SQL Job which picks up the job from MSDB?
Random Solutions  
 
programming4us programming4us