ARRAY<T>
Translation specification for the ARRAY<T> datatype from BigQuery to Snowflake
Description
Sample Source Patterns
Setup data
Input Code:
CREATE TABLE test.arrayTable
(
col1 ARRAY<INT64>
);
CREATE TABLE test.anotherArrayTable
(
col2 ARRAY<INT64>
);
INSERT INTO test.arrayTable VALUES ([4, 10, 55]);
INSERT INTO test.arrayTable VALUES ([6, 7, 33]);
INSERT INTO test.arrayTable VALUES ([50, 12, 22]);
INSERT INTO test.anotherArrayTable VALUES ([9, 11, 52]);
INSERT INTO test.anotherArrayTable VALUES ([3, 18, 11]);
INSERT INTO test.anotherArrayTable VALUES ([33, 27, 43]);Output Code:
ARRAY access by index
Input Code:
Output Code:
Safe ARRAY access by index
Input Code:
Output Code:
INSERT with ARRAY in the VALUES clause
Input Code:
Output Code:
MERGE statement
Input Code:
Output Code:
ARRAY DEFAULT column value insertion/update
Input Code:
Output Code:
INSERT/UPDATE with NULL value
Input Code:
Output Code:
ARRAY concatenation
Input Code:
Output Code:
ARRAY used as parameter/return type
Input Code:
Output Code:
Known Issues
Related EWIs
Last updated
