Get-AzureSqlServerAuditingPolicy

Get-AzureSqlServerAuditingPolicy

Gets the auditing policy of an Azure SQL server.

Syntax

Parameter Set: Default
Get-AzureSqlServerAuditingPolicy [-ResourceGroupName] <String> -ServerName <String> [-Profile <AzureProfile> ] [ <CommonParameters>]

Detailed Description

The Get-AzureSqlServerAuditingPolicy cmdlet gets the auditing policy of an Azure SQL server. Specify the ResourceGroupName, ServerName, and DatabaseName parameters to identify the database. This cmdlet returns a policy that is used by the Azure SQL databases that are both defined in the specified Azure SQL server and use its auditing policy.

Parameters

-Profile<AzureProfile>

Specifies the Azure profile from which this cmdlet reads. If you do not specify a profile, this cmdlet reads from the local default profile.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ResourceGroupName<String>

Specifies the name of the resource group that contains the Azure SQL server.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

true(ByPropertyName)

Accept Wildcard Characters?

false

-ServerName<String>

Specifies the name of the Azure SQL server for which this cmdlet gets an auditing policy.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

true(ByPropertyName)

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see    about_CommonParameters.

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

Outputs

The output type is the type of the objects that the cmdlet emits.

Examples

Example 1: Get the auditing policy of an Azure SQL server

This command gets the auditing policy of the server Server02 in resource group ResourceGroup11.

PS C:\> Get-AzureSqlServerAuditingPolicy -ResourceGroupName "ResourceGroup11" -ServerName "Server02"

Set-AzureSqlServerAuditingPolicy

Use-AzureSqlServerAuditingPolicy