Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

how to create .avsc file

Highlighted

how to create .avsc file

New Contributor

i am trying to create Hive table for avro, but i want to create .avsc file also for declaring schema of avro file using java

  1. CREATE TABLE doctors ROW FORMAT
  2. SERDE 'org.apache.hadoop.hive.serde2.avro.AvroSerDe'
  3. STORED AS
  4. INPUTFORMAT 'org.apache.hadoop.hive.ql.io.avro.AvroContainerInputFormat'
  5. OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.avro.AvroContainerOutputFormat' TBLPROPERTIES ('schema.avro.url'={'.avsc'}
  6. i have column name and datatype in csv file.
  7. please suggest how to create.