Replication script generate via powershell

  • Thread starter Prabhu ShankarM
  • Start date
P

Prabhu ShankarM

Hi,I am trying to generate replication create script for all the publications through SQL agent job calling powershell script.Script works well in lower version of SQL server, but i am getting below error while running in SQL 2022.Can someone help me identify what could be the possible fault.A job step received an error at line 37 in a PowerShell script. The corresponding line is '$repsvr=New-Object "Microsoft.SqlServer.Replication.ReplicationServer" $sqlserver '. Correct the script and reschedule the job. The error information returned by PowerShell is: 'Could not load file or assembly 'Micro

Continue reading...
 
Back
Top Bottom