IDENTITY

Description

Specifies that the column is an IDENTITY column.

Click here to navigate to the Amazon Redshift docs page for this syntax.

Grammar Syntax

IDENTITY ( seed, step )

Sample Source Patterns

RedShift Input Code:

IN -> Redshift_01.sql
CREATE TABLE table1 (
    col1 INTEGER IDENTITY(1,1)
);

Snowflake Output Code:

OUT -> Redshift_01.sql
CREATE OR REPLACE SEQUENCE table1_col1
START WITH 1
INCREMENT BY 1
ORDER
COMMENT = 'FOR TABLE-COLUMN table1.col1';

CREATE OR REPLACE TABLE table1 (
    col1 INTEGER DEFAULT table1_col1.NEXTVAL
)
COMMENT = '{ "origin": "sf_sc", "name": "snowconvert", "version": {  "major": 0,  "minor": 0,  "patch": "0" }, "attributes": {  "component": "redshift",  "convertedOn": "09/17/2024" }}'
;

There are no known issues.

Last updated