Like Table

Description

Specifies that the columns of the table have the same name and description as the columns of the specified table.

Grammar Syntax

<like clause> ::=
  LIKE <table name>  [ <like options>  ]
  <like options> ::=
  <like option> ...
<like option> ::=
    <identity option> 
  | <column default option> 
  | <generation option>   
<identity option> ::=
    INCLUDING IDENTITY
  | EXCLUDING IDENTITY
<column default option> ::=
    INCLUDING DEFAULTS
  | EXCLUDING DEFAULTS
<generation option> ::=
    INCLUDING GENERATED
  | EXCLUDING GENERATED

Click herearrow-up-right to go to the ANSI SQL Standard specification for this syntax.

circle-info

LIKE TABLES are partially supported in Snowflake. The like options doesn't not apply in Snowflake

Sample Source Patterns

ANSI SQL Input Code

Snowflake Output Code

  1. MSCEWI1002arrow-up-right: Removed next statement, not applicable in SnowFlake

Last updated

Was this helpful?