transfer_procedure
Relocate a stored procedure to a target schema using ALTER SCHEMA ... TRANSFER. Note that the procedure's internal definition retains the original schema name.
Instructions
Move a stored procedure to another schema via ALTER SCHEMA ... TRANSFER OBJECT::....
Stored procedures are supported on both Fabric Data Warehouses and
SQL Analytics Endpoints; unlike transfer_table, no endpoint guard
is applied here.
CAUTION: ALTER SCHEMA ... TRANSFER moves the procedure but does
NOT rewrite the schema name inside its stored definition. After a
transfer, get_procedure may still show the OLD schema name in the
CREATE ... AS header even though the procedure now lives in the
new schema.
Args:
workspace: Workspace name or GUID.
item: Warehouse or SQL endpoint name or GUID.
qualified_name: Current dot-separated qualified procedure name,
e.g. dbo.usp_load.
target_schema: Schema to move the procedure into, e.g. archive.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| item | Yes | ||
| workspace | Yes | ||
| target_schema | Yes | ||
| qualified_name | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||