blob: 4c9539c767d277253debd1eb0c1fa3bcde0ef8a9 [file] [log] [blame]
-- File Schema { "name" : "val", "type" : [ "null", "int" ] }
-- Record Schema { "name" : "val", "type" : [ "long", "null" ] }
DROP TABLE IF EXISTS avro_type_evolution;
CREATE TABLE avro_type_evolution (val bigint) STORED AS AVRO
TBLPROPERTIES (
'avro.schema.literal'='{
"type" : "record",
"name" : "type_evolution",
"namespace" : "default",
"fields" : [ {
"name" : "val",
"type" : [ "long", "null" ]
} ]
}');
LOAD DATA LOCAL INPATH '../../data/files/type_evolution.avro' OVERWRITE INTO TABLE avro_type_evolution;
SELECT * FROM avro_type_evolution;
DROP TABLE avro_type_evolution;