Skip to content

Cloning

  • Not cloned: internal named stages, external tables
  • Pipes: auto_ingest = false pipes are paused, auto_ingest = true pipes are stopped_cloned (doesn't accumulate events)
  • can clone a perm table as transient; only newly created partitions become transient
  • cloned stages are empty, i.e. do not contain any files from the source
  • cloned table's streams offset are reset to cloning time => unconsumed rows are inaccessible
  • the cloned object itself doesn't inherit permissions, but the child objects inherit permissions of cloned objects

Considerations

  • copy grants inherits explicit grants but not future grants
  • if no copy grants was used, the cloned objects inherits from future grants
  • named internal stages:
    • cloned only as part of database or schema level cloning
    • uses directory table as source of truth, BP refresh directory
    • clones of stages without directory are empty
    • time-travel is ignored, unless it's before the stage was created, in that case it's skipped
property Effect
sequence May refer orig (1)
foreign-key May refer orig
clustering auto-clustering paused
internal table stages table stages are empty
table load history not copied
internal pipes not cloned
external pipes auto_ingest => stopped, else paused
tags may refer orig
java UDF UDF's jar must be outside the source schema/database
  1. sequence in cloned table can be reset using alter table ... set ... to change sequence