PowerShell error with Get-SqlMonitorCluster
Andrew_Price
Posts: 4 New member
Code that worked before appears broken in 10.2.8.631
Using code:
Using code:
using module 'redacted\RedgateSQM'
Connect-SqlMonitor -ServerURL 'http://redacted' -AuthToken 'redacted'
Get-SqlMonitorCluster
Results in error:
Results in error:
Cannot convert value "@{BaseMonitor=; Type=Cluster; DisplayType=Cluster;
| FullName=redacted; Group=; Id=redacted;
| Name=redacted}" to type "Cluster". Error: "Cannot convert the "@{BaseMonitor=;
| Type=Cluster; DisplayType=Cluster; FullName=redacted; Group=;
| Id=redacted; Name=redacted}" value of type
| "System.Management.Automation.PSCustomObject" to type "Cluster"."
I know I am connected as other commands like Get-SqlMonitorBaseMonitor work just fine.
Thanks for any help or insight you can provide.
Andrew
I know I am connected as other commands like Get-SqlMonitorBaseMonitor work just fine.
Thanks for any help or insight you can provide.
Andrew
Tagged:
Answers
I think you may need to re download the latest PowerShell Module, extract the new files and then restart your PowerShell session. I've just done the same thing where I updated to 10.2.8, had an old RedgateSQM module and go the same error and updating fixes it. (need to restart PoSh)
Have you visited our Help Center?