SQL Monitor 12

Help for older versions available.

These pages cover SQL Monitor 12, which is not the latest version. Help for other versions is also available.

PowerShell Cmdlets

This page will give an overview of how to access information about the PowerShell Cmdlets provided by the SQL Monitor PowerShell Module.

Once you have imported the PowerShell Module, you can view a list of the available Cmdlets using the following command:

  1. Get-Command -Module RedgateSQM | Select Name

This will give you an output like this:

  1. Name
  2. ----
  3. Add-SqlMonitorAccessRights
  4. Add-SqlMonitorAnnotation
  5. Add-SqlMonitorMonitoredObject
  6. Connect-SqlMonitor
  7. Get-SqlMonitorADPrincipal
  8. Get-SqlMonitorAlertSettings
  9. Get-SqlMonitorAlertSuppressionWindow
  10. Get-SqlMonitorAmazonRdsSqlServer
  11. Get-SqlMonitorAnnotation
  12. Get-SqlMonitorAvailabilityGroup
  13. Get-SqlMonitorAzureManagedInstance
  14. Get-SqlMonitorAzureSqlServer
  15. Get-SqlMonitorBaseMonitor
  16. Get-SqlMonitorCluster
  17. Get-SqlMonitorDatabase
  18. Get-SqlMonitorDisk
  19. Get-SqlMonitorElasticPool
  20. Get-SqlMonitorGroup
  21. Get-SqlMonitorInstance
  22. Get-SqlMonitorJob
  23. Get-SqlMonitorMachine
  24. Get-SqlMonitorMainGroups
  25. Get-SqlMonitorMonitoredObjectStatus
  26. Get-SqlMonitorSubGroups
  27. New-SqlMonitorADPrincipal
  28. New-SqlMonitorAlertSpecificSettings
  29. New-SqlMonitorAlertSuppressionWindow
  30. New-SqlMonitorGroup
  31. Remove-SqlMonitorAccessRights
  32. Remove-SqlMonitorADPrincipal
  33. Remove-SqlMonitorAlertSuppressionWindow
  34. Remove-SqlMonitorAnnotation
  35. Remove-SqlMonitorGroup
  36. Remove-SqlMonitorMonitoredObject
  37. Test-SqlMonitorGroupAccess
  38. Test-SqlMonitorMonitoredObjectAccess
  39. Update-SqlMonitorADPrincipal
  40. Update-SqlMonitorAlertNotificationSettings
  41. Update-SqlMonitorAlertSettingsComments
  42. Update-SqlMonitorAlertSettingsStatus
  43. Update-SqlMonitorAlertSpecificSettings
  44. Update-SqlMonitorAlertSuppressionWindow
  45. Update-SqlMonitorAnnotation
  46. Update-SqlMonitorMonitoredObjectSuspendedStatus


For details on a specific Cmdlet, you can use the built-in PowerShell function Get-Help . For instance, if you wanted to find out the specifics of the Update-SqlMonitorAlertSpecificSettings  Cmdlet, you would use:

  1. Get-Help Update-SqlMonitorAlertSpecificSettings

The output would look something like this:

  1. Get-Help Update-SqlMonitorAlertSpecificSettings
  2.  
  3. NAME
  4. Update-SqlMonitorAlertSpecificSettings
  5.  
  6. SYNOPSIS
  7. Updates the alert settings for a specific alert type and target monitored object.
  8.  
  9.  
  10. SYNTAX
  11. Update-SqlMonitorAlertSpecificSettings [-MonitoredObject] <MonitoredObject> [-AlertType] <Int32> [-Settings] <SpecificAlertSettings> [<CommonParameters>]
  12.  
  13.  
  14. DESCRIPTION
  15. Updates the alert settings for a specific alert type and monitored object. The alert settings object will depend on the alert type.
  16.  
  17.  
  18. RELATED LINKS
  19.  
  20. REMARKS
  21. To see the examples, type: "Get-Help Update-SqlMonitorAlertSpecificSettings -Examples"
  22. For more information, type: "Get-Help Update-SqlMonitorAlertSpecificSettings -Detailed"
  23. For technical information, type: "Get-Help Update-SqlMonitorAlertSpecificSettings -Full"


Many of the Cmdlets take in parameters of types defined by the SQL Monitor PowerShell Module. For clarification on these types, view the Custom Types page. You can also consult the example scripts available in SQL Monitor itself for further guidance.


Do you have any feedback on this documentation?

Let us know at sqlmonitorfeedback@red-gate.com


Didn't find what you were looking for?