< Back

Set-AzureRmSqlElasticPoolAdvisorAutoExecuteStatus

Tue Jan 29, 2019 10:10 pm

NAME Set-AzureRmSqlElasticPoolAdvisorAutoExecuteStatus



SYNOPSIS

Updates auto execute status of an Azure SQL Elastic Pool Advisor.





SYNTAX

Set-AzureRmSqlElasticPoolAdvisorAutoExecuteStatus [-ResourceGroupName] <String> -AdvisorName <String> -AutoExecuteStatus {Enabled | Disabled |

Default} [-DefaultProfile <IAzureContextContainer>] -ElasticPoolName <String> -ServerName <String> [-Confirm] [-WhatIf] [<CommonParameters>]





DESCRIPTION

The Set-AzureRmSqlElasticPoolAdvisorAutoExecuteStatus cmdlet sets auto execute property for an Azure SQL Elastic Pool Advisor.





PARAMETERS

-AdvisorName <String>

Specifies the name of the advisor for which this cmdlet updates the auto execute status.



Required? true

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-AutoExecuteStatus <AdvisorAutoExecuteStatus>

Specifies a new value to which this cmdlet updates the auto execute status.



The acceptable values for this parameter are:



- Enabled



- Disabled



- Default



Required? true

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-DefaultProfile <IAzureContextContainer>

The credentials, account, tenant, and subscription used for communication with azure



Required? false

Position? named

Default value None

Accept pipeline input? False

Accept wildcard characters? false



-ElasticPoolName <String>

Specifies the name of the elastic pool.



Required? true

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-ResourceGroupName <String>

Specifies the name of the resource group of the server that contains this elastic pool.



Required? true

Position? 0

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-ServerName <String>

Specifies the name of the server the elastic pool is in.



Required? true

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-Confirm [<SwitchParameter>]

Prompts you for confirmation before running the cmdlet.



Required? false

Position? named

Default value False

Accept pipeline input? False

Accept wildcard characters? false



-WhatIf [<SwitchParameter>]

Shows what would happen if the cmdlet runs. The cmdlet is not run.



Required? false

Position? named

Default value False

Accept pipeline input? False

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).



INPUTS

None

This cmdlet does not accept any input.





OUTPUTS

Microsoft.Azure.Commands.Sql.Advisor.Model.AzureSqlElasticPoolAdvisorModel







NOTES





* Keywords: azure, azurerm, arm, resource, management, manager, sql, elastic pool, mssql, advisor



Example 1: Enable auto execute for an advisor



PS C:\\>Set-AzureRmSqlElasticPoolAdvisorAutoExecuteStatus -ResourceGroupName "WIRunnersProd" -ServerName "wi-runner-australia-east"

-ElasticPoolName "WIRunnerPool" -AdvisorName "CreateIndex" -AutoExecuteStatus Enabled

'Enabled'ElasticPoolName : WIRunnerPool

ResourceGroupName : WIRunnersProd

ServerName : wi-runner-australia-east

AdvisorName : CreateIndex

AdvisorStatus : GA

AutoExecuteStatus : Enabled

AutoExecuteStatusInheritedFrom : ElasticPool

LastChecked : 8/1/2016 2:36:47 PM

RecommendationsStatus : Ok

RecommendedActions : {}



This command sets the auto execute status of an advisor named CreateIndex to enabled.







RELATED LINKS

Online Version: https://docs.microsoft.com/en-us/powers ... cutestatus

Get-AzureRmSqlElasticPoolAdvisor

SQL Database Documentation https://docs.microsoft.com/azure/sql-database/