Column Definition

The table's schema information

Grammar syntax

column :=
  col_name data_type [column_constraint_specification] 
  [COMMENT col_comment], ...

column_constraint_specification:
  : [ PRIMARY KEY|UNIQUE|NOT NULL|DEFAULT [default_value]|CHECK [check_expression] ENABLE|DISABLE NOVALIDATE RELY/NORELY ]
 
default_value:
  : [ LITERAL|CURRENT_USER()|CURRENT_DATE()|CURRENT_TIMESTAMP()|NULL ] 
 

Data types

Click here for more information about the translation spec for data types. Also, see more information about data types in Hive here.

Sample Source

1. COMMENT

The syntax is equivalent in both languages.

2. Primary Key

The syntax is equivalent in both languages.

3. Unique

The syntax is equivalent in both languages.

4. Default default_expression

The default value assigned to the column

The syntax is equivalent in both languages.

5. Not null

The syntax is equivalent in both languages.

6. Check

Known Issues

No issues were found.

  1. MSC-HVXXXX : THE CREATE TABLE CHECK CONSTRAINT IS NOT SUPPORTED IN SNOWFLAKE.

Last updated

Was this helpful?