Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Execute Process Task calling SQMCMD Expand / Collapse
Author
Message
Posted Thursday, November 12, 2009 10:12 AM


SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Friday, September 5, 2014 9:10 PM
Points: 163, Visits: 569
I have a script that runs transaction code to backup, copy, and restore a database. The backup is from a source database, the copy is to a UNC location on the destination server, and the restore is the the SQL instance installed on the destination server. The script I'm running works when run through the SSMS interface when using SQLCMD mode. I'm trying to create a SSIS package that runs the script on the source server/instance. The source is where the package would reside.

I have tried creating a Execute Process Task to run SQLCMD and have the task point to my script file location but it is failing. I have two data sources configured to include the source database and the destination database, same with the connection manager configuration. The script runs T-SQL code that runs stored procedures that are in the SQL Safe product

I'm not sure I'm going about this the right way? Shouldn't all that be needed is a Execute Process Task that runs SQLCMD which then reads the script from the script file, and two data source and connection manager connections?

Here is the error message I'm receiving:

SSIS package "Package.dtsx" starting.
Error: 0xC0029151 at Execute Process Task, Execute Process Task: In Executing "C:\Program Files\Microsoft SQL Server\100\Tools\Binn\SQLCMD.EXE" "-E -SeanDeYoung760 -i 'c:\Documents and Settings\Sean.DeYoung\My Documents\Script\script.sql'" at "", The process exit code was "1" while the expected was "0".
Task failed: Execute Process Task
Warning: 0x80019002 at Package: SSIS Warning Code DTS_W_MAXIMUMERRORCOUNTREACHED. The Execution method succeeded, but the number of errors raised (1) reached the maximum allowed (1); resulting in failure. This occurs when the number of errors reaches the number specified in MaximumErrorCount. Change the MaximumErrorCount or fix the errors.
SSIS package "Package.dtsx" finished: Failure.

Any help or







A clever person solves a problem. A wise person avoids it.
A clever person solves a problem. A wise person avoids it.



A clever person solves a problem. A wise person avoids it. ~ Einstein
select cast (0x5365616E204465596F756E67 as varchar(128))
Post #817963
Posted Thursday, November 12, 2009 10:21 AM


SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Friday, September 5, 2014 9:10 PM
Points: 163, Visits: 569
...






A clever person solves a problem. A wise person avoids it.
A clever person solves a problem. A wise person avoids it.



A clever person solves a problem. A wise person avoids it. ~ Einstein
select cast (0x5365616E204465596F756E67 as varchar(128))
Post #817967
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse