Clones a schema.

POST {{baseUrl}}/api/v2/databases/:database/schemas/{{name}}:clone?createMode=errorIfExists&kind=&targetDatabase=F7o

Clones an existing schema, with modifiers as query parameters. You must provide the full schema definition when cloning an existing schema.

Request Params

KeyDatatypeRequiredDescription
createModestringQuery parameter allowing support for different modes of resource creation. Possible values include:
  • errorIfExists: Throws an error if you try to create a resource that already exists.
  • orReplace: Automatically replaces the existing resource with the current one.
  • ifNotExists: Creates a new resource when an alter is requested for a non-existent resource. | | kind | null | | Type of schema to clone. Currently, Snowflake supports only transient and permanent (also represented by the empty string). | | targetDatabase | string | | Database of the newly created schema. Defaults to the source schema's database. |

Request Body

{"name"=>"\"v#\"", "point_of_time"=>{"point_of_time_type"=>"e", "reference"=>"nisi dolor"}, "created_on"=>"<dateTime>", "kind"=>"PERMANENT", "is_default"=>"<boolean>", "is_current"=>"<boolean>", "database_name"=>"<string>", "owner"=>"<string>", "comment"=>"<string>", "options"=>"<string>", "managed_access"=>false, "retention_time"=>"<integer>", "dropped_on"=>"<dateTime>", "owner_role_type"=>"<string>", "budget"=>"<string>", "data_retention_time_in_days"=>"<integer>", "default_ddl_collation"=>"<string>", "log_level"=>"<string>", "pipe_execution_paused"=>"<boolean>", "max_data_extension_time_in_days"=>"<integer>", "suspend_task_after_num_failures"=>"<integer>", "trace_level"=>"<string>", "user_task_managed_initial_warehouse_size"=>"<string>", "user_task_timeout_ms"=>"<integer>"}

HEADERS

KeyDatatypeRequiredDescription
Content-Typestring
Acceptstring

RESPONSES

status: OK

{&quot;status&quot;:&quot;\u003cstring\u003e&quot;}