Hi guys,

I`m working on creation external Hive tables from Avro files using column-based 
approach:
CREATE TABLE kst (
    string1 string,
    string2 string,
    int1 int,
    boolean1 boolean,
    long1 bigint,
    float1 float,
    double1 double,
    inner_record1 
struct<int_in_inner_record1:int,string_in_inner_record1:string>,
    enum1 string,
    array1 array<string>,
    map1 map<string,string>,
    union1 uniontype<float,boolean,string>,
    fixed1 binary,
    null1 void,
    unionnullint int,
    bytes1 binary)
  PARTITIONED BY (ds string)
  STORED AS AVRO;

And faced with case sensitive issue:
If I have column in Avro as String1, it will be not found in dataset and I will 
get default NULL, cause Hive will transform it to lowercase “string1”.

Similar issue was with Parquet https://issues.apache.org/jira/browse/HIVE-7554 
and was resolved by extending properties.

Is there any work around except using avro.schema.url or avro.schema.literal ?



Reply via email to