Skip to content

Instantly share code, notes, and snippets.

@andrewstevenson
Created September 11, 2016 17:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save andrewstevenson/54a837e11521535faed668d5f3c99506 to your computer and use it in GitHub Desktop.
Save andrewstevenson/54a837e11521535faed668d5f3c99506 to your computer and use it in GitHub Desktop.
CREATE TABLE example
ROW FORMAT SERDE
'org.apache.hadoop.hive.serde2.avro.AvroSerDe'
STORED AS INPUTFORMAT
'org.apache.hadoop.hive.ql.io.avro.AvroContainerInputFormat'
OUTPUTFORMAT
'org.apache.hadoop.hive.ql.io.avro.AvroContainerOutputFormat'
TBLPROPERTIES (
'avro.schema.literal'='hdfs//your-name-node:port/path/to/schema.json')
LOCATION /data/flume/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment