Row Format
Create table option
Description
ROW FORMAT
clause in the CREATE TABLE
statement is used to specify how the data rows are formatted within the underlying storage. It defines the serialization and deserialization format for the data stored in the table. The ROW FORMAT
clause is often used in conjunction with the STORED AS
clause to define the overall storage format for the table. For more information please refer to Row Formats & SerDe
ROW FORMAT
clause is not supported by Snowflake.
Grammar Syntax
ROW FORMAT row_format
row_format:
: SERDE serde_class [ WITH SERDEPROPERTIES (k1=v1, k2=v2, ... ) ]
| DELIMITED [ FIELDS TERMINATED BY fields_terminated_char [ ESCAPED BY escaped_char ] ]
[ COLLECTION ITEMS TERMINATED BY collection_items_terminated_char ]
[ MAP KEYS TERMINATED BY map_key_terminated_char ]
[ LINES TERMINATED BY row_terminated_char ]
[ NULL DEFINED AS null_char ]
Sample Source
Hive
CREATE TABLE table1 (
col1 STRING
)
ROW FORMAT SERDE 'org.apache.hadoop.hive.serde2.avro.AvroSerDe';
CREATE TABLE table2 (
col1 STRING
)
ROW FORMAT DELIMITED FIELDS TERMINATED BY ',';
Snowflake
CREATE TABLE table1 (
col1 STRING
)
----** MSC-HVXXXX: THE ROW FORMAT CLAUSE IS NOT SUPPORTED IN SNOWFLAKE.
--ROW FORMAT SERDE 'org.apache.hadoop.hive.serde2.avro.AvroSerDe';
CREATE TABLE table2 (
col1 STRING
)
----** MSC-HVXXXX: THE ROW FORMAT CLAUSE IS NOT SUPPORTED IN SNOWFLAKE.
--ROW FORMAT DELIMITED FIELDS TERMINATED BY ',';
Known Issues
In Snowflake, you don't need to specify row formats or delimiters explicitly during table creation.
Related EWIs
MSC-HVXXXX: THE ROW FORMAT CLAUSE IS NOT SUPPORTED IN SNOWFLAKE.
Last updated
Was this helpful?