I have a 32 bit SSIS package that I need to call from a stored procedure in MS SQL. I need to call the 32 bit version of DTExec.exe. But I am having pathing issues using the xp_cmdshell. I have also tried it without the double quotes.
The error I am getting with this code is: 'C:\Program' is not recognized as an internal or external command,
-- code --
DECLARE @ReturnCode int
DECLARE @SqlQuery nvarchar(2000)
set @SqlQuery = '"C:\Program Files (x86)\Microsoft SQL Server\100\DTS\Binn\DTExec.exe" /SQL "pkgAbraTransferSpreadsheet" '
print '*' + @sqlQuery + '*'
EXEC @ReturnCode = master..xp_cmdshell @SqlQuery
print 'return code: ' + convert(nvarchar(15),@returncode)