Remove-SCSQLDeployment

Removes a SQL Server deployment from a SQL profile.

Description

The Remove-SCSQLDeployment cmdlet removes a SQL Server deployment from a SQL profile.

For more information about Remove-SCSQLDeployment, type: "Get-Help Remove-SCSQLDeployment -online".

Parameters

SQLDeployment

Required? true
Accept Pipeline Input? true (ByValue)
Position? 0
Specifies a SQL Server deployment object.

Confirm

Required? false
Accept Pipeline Input? false
Position? named
Prompts for confirmation before running the command.

JobVariable

Required? false
Accept Pipeline Input? false
Position? named
Specifies that job progress is tracked and stored in the variable named by this parameter. 

PROTipID

Required? false
Accept Pipeline Input? false
Position? named
Specifies the ID of the PRO tip that triggered this action. This allows for auditing of PRO tips.

RunAsynchronously

Required? false
Accept Pipeline Input? false
Position? named
Indicates that the job runs asynchronously so that control returns to the command shell immediately. 

Examples

1: Remove a SQL Server deployment from a SQL profile.
PS C:\> $SQLProfile = Get-SCSQLProfile -Name "SQLProfile01"
PS C:\> $SQLDeployment = Get-SCSQLDeployment -SQLProfile $SQLProfile -Name "SQL Deployment 01"
PS C:\> Remove-SCSQLDeployment -SQLDeployment $SQLDeployment
The first command gets the SQL Server profile object named SQLProfile01 and stores the object in the $SQLProfile variable.

The second command gets the SQL Server deployment object named SQL Deployment 01 from the SQL profile stored in $SQLProfile and then stores the object in the $SQLDeployment variable.

The last command removes the SQL Server deployment stored in $SQLDeployment from the SQL Server profile stored in $SQLProfile.

See Also