hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Divya Ravishankar <>
Subject Case sensitive column names during HIVE table creation
Date Mon, 09 Jun 2014 16:55:53 GMT

I am trying to create an external HIVE table with partitions. Some of my
column names have Upper case letters. This caused a problem while creating
tables since the values of column names with upper case letters were
returned as NULL. I then modified the ParquetSerDe in order for it to
handle this by using SERDEPROPERTIES and this was working now. Now I am
trying to create an external table with partitions, whenever I try to
access the upper case columns (Eg FieldName) I get this error.
select FieldName from tablename;
FAILED: RuntimeException Java. Lang.RuntimeException: cannot find field
FieldName from [org.apache.hadoop.hive.serde2.objectinspector.
UnionStructObjectInspector$MyField@4f45884b, org.apache.hadoop.hive.serde2.
objectinspector.UnionStructObjectInspector$MyField@8f11f27, org.apache.
UnionStructObjectInspector$MyField@77e8eb0e, org.apache.hadoop.hive.serde2.
objectinspector.UnionStructObjectInspector$MyField@1dae4cd, org.apache.

Are there any suggestions you can think of?

This is the command I use to create tables -

CREATE EXTERNAL TABLE tablename (fieldname string)

PARTITIONED BY (partion_name string)

ROW FORMAT SERDE 'path.ModifiedParquetSerDeLatest'

WITH SERDEPROPERTIES ("casesensitive"="FieldName")

STORED AS INPUTFORMAT 'parquet.hive.DeprecatedParquetInputFormat'

OUTPUTFORMAT 'parquet.hive.DeprecatedParquetOutputFormat'
location 'path to location';

Divya Ravishankar

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message