I have created SQL Server Agent job and has 2 steps
step 1) Run powershell command Powershell.exe -file 'C:\script\psfile.ps1'
step2) Run t-sql command.
When I scheduled the SQL Server agent job . It is successfully completing without running step1. and Step1 is not even creating any output file which i have defined on the job step 1 .
When I run powershell command or powershell file itself , it is executing successfully on powershell ISE..
Can some advice the solution for this?
job step is running under SQL Server agent service account which has admin right on SQL Server and Windows level.