Home Forums Programming Powershell powershell script through agent job only performing half the steps it should. RE: powershell script through agent job only performing half the steps it should.

  • I do something similiar, with a couple of differences. One, I run the step as type PowerShell. The other thing I do, and I suspect this may be your problem, I have a proxy login, that has access to the other servers. Then I change the Run as option to the proxy. Otherwise, the SQL job will run, using the SQL Server agent service account. I do use Windows Authentication, so if you are using SQL login, in your Powershell script, then you should be ok. Since you said you are using cmdexec, i assume you are running a bat file, or executing the powershell exe?

    Leonard