user1027076
user1027076

Reputation: 175

"The command line parameters are invalid" error when running job from SQL Agent

Error :

Argument "ETL" for option "connection" is not valid.  
The command line parameters are invalid.  The step failed.

While executing the Job in SQL Server Agent.

Upvotes: 2

Views: 14439

Answers (4)

Glen
Glen

Reputation: 830

I also had a similar problem, I made a change deployed and it stop working, I tried to remove spaces and hyphens as suggested above (I have 2 connections at fault) and still nothing, well it did make an effect as in the error message switched from one connection to the other - arrrgh, after pulling all my hair out all day. I just had a thought to delete the job and recreate and it worked! Also BIDs I definitely think there is some kind of configuration bug in that after you deploy and try to manually change the connection manager it fails, so my workaround is to configure first, then deploy, (delete existing job if present) then create the job, so repeat for each environment u need to deploy to.

Upvotes: 0

Craig Dawson
Craig Dawson

Reputation: 1

I had a similar issue where the paramater value ended in a backslash. I just removed it and appended it back in an expression within the SSIS package.

Upvotes: 0

Sathiya Kumar V M
Sathiya Kumar V M

Reputation: 517

Today I faced exactly same issue and I fixed it. What I did is, renamed connection name (without space, dots,hyphen) in my SSIS package. Previously I had default connection name so it showed error as

Argument "****" for option "connection" is not valid. The command line parameters are invalid. The step failed.

later I changed both source and destination connection names(without space) and used those packages while scheduling Job in SQL Server Agent and tried Start Jot at Step and succeeded.

Upvotes: 1

criticalfix
criticalfix

Reputation: 2870

This is often a problem with parameter configuration, see e.g. here.

When you run from inside BIDS, you are in an environment where your parameters are available. When you schedule an SSIS package as a SQL Server job, those parameters have to come from somewhere. You can reference them in a configuration file, and you can override them in the configuration tab for the job.

Upvotes: 4

Related Questions