Using

In this section, you will find information about Spark's USING statement and their Snowflake equivalent.

Description

USING command in spark create table is to indicate the file format to use for the table. For example CSV, JSON, AVRO, etc. You can find more information about Create table USING here.

Syntax

CREATE TABLE [IF NOT EXISTS] [db_name.]table_name
  [(col_name1 col_type1 [COMMENT col_comment1], ...)]
  USING data_source
  [OPTIONS (key1 [ = ] val1, key2 [ = ] val2, ...)]
  [PARTITIONED BY (col_name1, col_name2, ...)]
  [CLUSTERED BY (col_name3, col_name4, ...) INTO num_buckets BUCKETS]
  [LOCATION path]
  [COMMENT table_comment]
  [TBLPROPERTIES (key1 [ = ] val1, key2 [ = ] val2, ...)]
  [AS select_statement]

Sample source patterns

USING data source is not supported in snowflake so in migration this statement will be comment and indicated with an EWI that is not supported

Sample data

CREATE TABLE table1
(
id INTEGER
) USING DELTA;
CREATE TABLE table1
(
id INTEGER
) /*** MSC-WARNING - MSCEWI# - SNOWFLAKE DOES NOT SUPPORT USING STATEMENT ***/
-- USING DELTA;

Known Issues

Snowflake does not support USING data source.

  • SNOWFLAKE DOES NOT SUPPORT USING STATEMENT.

Last updated