The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
serverName
path
True
string
The name of the server.
subscriptionId
path
True
string
The subscription ID that identifies an Azure subscription.
workloadGroupName
path
True
string
The name of the workload group to delete.
api-version
query
True
string
The API version to use for the request.
Responses
Name
Type
Description
200 OK
Successfully deleted the workload group.
202 Accepted
Deleting the workload group is in progress.
204 No Content
The specified workload group does not exist.
Other Status Codes
*** Error Responses: ***
400 OperationNotAllowedOnPausedDatabase - Operation is not allowed on a paused database.
400 FeatureDisabledOnSelectedEdition - User attempted to use a feature which is disabled on current database edition.
404 SubscriptionDoesNotHaveServer - The requested server was not found
404 ServerNotInSubscriptionResourceGroup - Specified server does not exist in the specified resource group and subscription.
404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance.
404 ResourceNotFound - The requested resource was not found.
404 OperationIdNotFound - The operation with Id does not exist.
409 ConflictingDatabaseOperation - There is already some operation on the database and the current operation should wait till it is done.
409 ConflictingSystemOperationInProgress - A system maintenance operation is in progress on the database and further operations need to wait until it is completed.
409 OperationCancelled - The operation has been cancelled by user.
409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.
429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.
429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.
500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.
503 TooManyRequests - Requests beyond max requests that can be processed by available resources.
503 DatabaseUnavailable - The operation failed because the database is unavailable.
503 TooManyRequests - Requests beyond max requests that can be processed by available resources.
504 RequestTimeout - Service request exceeded the allowed timeout.
/**
* Samples for WorkloadGroups Delete.
*/
public final class Main {
/*
* x-ms-original-file:
* specification/sql/resource-manager/Microsoft.Sql/stable/2021-11-01/examples/DeleteWorkloadGroup.json
*/
/**
* Sample code: Delete a workload group.
*
* @param azure The entry point for accessing resource management APIs in Azure.
*/
public static void deleteAWorkloadGroup(com.azure.resourcemanager.AzureResourceManager azure) {
azure.sqlServers().manager().serviceClient().getWorkloadGroups().delete("Default-SQL-SouthEastAsia", "testsvr",
"testdb", "wlm_workloadgroup", com.azure.core.util.Context.NONE);
}
}