Click here to Skip to main content
15,891,726 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I have master package calling another package, but it failed when executing. Below is the error message returned:
SQL
[Execute Process Task] Error: In Executing 
"C:\Program Files (x86)\Microsoft SQL Server\100\DTS\Binn\DTExec.exe" "
/FILE "\\140.131.12.25\Work\Platform\Db\SSIS\TABLE_LOAD.dtsx" 
/SET \Package.Variables[User::controlCount].Properties[Value];"0" 
/SET \Package.Variables[User::fileID].Properties[Value];"1" 
/SET \Package.Variables[User::filePathName].Properties[Value];"\\140.131.12.25\work\_data_inbox\DHM\Compliance\Work\test.txt" 
/SET \Package.Variables[User::archivePath].Properties[Value];"\\140.131.12.25\work\_data_inbox\DHM\Compliance\Work\Archive\" 
/SET \Package.Variables[User::stageID].Properties[Value];"24" 
/SET \Package.Variables[User::MasterExceptionPkg].Properties[Value];"" 

/Conn OH_STAGE;Provider=SQLNCLI10.1;Server=140.131.12.25;Database=OH_STAGE;Trusted_Connection=yes;" at "", The process exit code was "6" while the expected was "0".


Here is the Argument I was using in Execute Process Task:
SQL
/FILE "" /SET \Package.Variables[User::controlCount].Properties[Value];"0" /SET \Package.Variables[User::fileID].Properties[Value];"23" /SET \Package.Variables[User::filePathName].Properties[Value];"" /SET \Package.Variables[User::archivePath].Properties[Value];"" /SET \Package.Variables[User::stageID].Properties[Value];"26" /SET \Package.Variables[User::MasterExceptionPkg].Properties[Value];


I use below script to debug the issue, found out the issue might be because of the password protect level. So I am wondering how do I add underline part to the Arguments . I am not sure that's the reason causing the failure, but still worth to try. When I run below script alone in SSMS, its calling another package successfully.
SQL
DECLARE @SQLQuery AS VARCHAR(2000)
Declare @param1 varchar(200)
Declare @param2 varchar(200)
Declare @param3 varchar(200)
Declare @param4 varchar(200)
Declare @param5 varchar(200)
Declare @param6 varchar(200)

SET @SQLQuery = 'DTExec /FILE "\\140.131.12.25\Work\Platform\Db\SSIS\TABLE_LOAD.dtsx" /DECRYPT "Password1"'

set @param1=' /SET \Package.Variables[User::controlCount].Properties[Value];"0"'
set @param2=' /SET \Package.Variables[User::fileID].Properties[Value];"23"'
set @param3=' /SET \Package.Variables[User::filePathName].Properties[Value];"\\140.131.12.25\work\_data_inbox\DHM\Compliance\Work\test.txt"'
set @param4=' /SET \Package.Variables[User::archivePath].Properties[Value];"\\140.131.12.25\work\_data_inbox\DHM\Compliance\Work\Archive\"'
set @param5=' /SET \Package.Variables[User::stageID].Properties[Value];"26"'
set @param6=' /SET \Package.Variables[User::MasterExceptionPkg].Properties[Value];""'

SET @SQLQuery = @SQLQuery+@param1+@param2+@param3+@param4+@param5+@param6

EXEC master..xp_cmdshell @SQLQuery
GO


Meanwhile, I would love to hear any of your thoughts. Thanks a lot
Posted

1 solution

Have you try to run your package in 32bit instead of 64bit (SSIS Default)?
 
Share this answer
 
Comments
tdai_dev 3-Dec-14 0:03am    
The server is 64 bit, so I have no choice. Thanks for the feedback
Lolo1986 3-Dec-14 0:46am    
It doesn't matter. Convert your package to run in 32bits. It will be compatible with your 64bit architecture.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900