Removes a stored procedure.
Remove-StoredProcedure [-Name] <String> [[-SchemaName] <String>] [<CommonParameters>]
Removes a stored procedure. Will throw an exception and rollback the migration if the stored procedure doesn't exist.
By default, the stored procedure is assumed to be in the dbo schema. Use the Schema parameter to specify a different schema.
You can conditionally delete a stored procedure only if it exists using the IfExists switch.
| Name | Type | Description | Required? | Pipeline Input | Default Value |
|---|---|---|---|---|---|
| Name | String | The name of the stored procedure to remove/delete. |
true | false | |
| SchemaName | String | The schema of the stored procedure. Default is |
false | false | dbo |
Remove-StoredProcedure -Name MySproc
Removes the dbo.MySproc stored procedure.
Remove-StoredProcedure -Name MySproc -SchemaName rivet
Removes the rivet.MySproc stored procedure.