AVRO Files
userdata.avro:
The Avro file has a header.
Column Details:
column# column_name hive_datatype
===============================================================
1 registration_dttm timestamp
- Create the external table:
CREATE EXTERNAL TABLE avro_ex_test (
registration_dttm TIMESTAMP,
REFERENCE='abfs://loadtest@avalanchetest.dfs.core.windows.net/userdata.avro',
FORMAT='com.databricks.spark.avro'
OPTIONS=('header' = 'true');
- Create the native Actian Data Platform table:
registration_dttm TIMESTAMP,
- Load the Actian Data Platform table with the INSERT command:
INSERT INTO avro_test SELECT * FROM avro_ex_test
Note
If the file does not have a header, include schema in OPTIONS, as shown in the external table to load an ORC file.