有人能帮我解决这个错误吗。由于此异常,我无法将配置单元数据加载到ElasticSearch。
--配置单元控制台代码
Hive>
> create external table petrol_es(distributer_id STRING,distributer_name STRING,amt_IN STRING,amy_OUT STRING,vol_IN INT,vol_OUT INT,year INT)
> ROW FORMAT SERDE 'org.elasticsearch.hadoop.hive.EsSerDe'
> STORED BY 'org.elasticsearch.hadoop.hive.EsStorageHandler'
> tblproperties('es.resource' = 'petrol/petrolCat');
OK
Time taken: 0.16 seconds
hive>
>
> select * from petrol_es;
OK
Failed with exception java.io.IOException:org.elasticsearch.hadoop.EsHadoopIllegalArgumentException: Index [petrol/petrolCat] missing and settings [es.field.read.empty.as.null] is set to false
Time taken: 0.156 seconds
hive>
>
>
1条答案
按热度按时间gmxoilav1#
添加“es.index.auto.create”=“true”、“es.index.read.missing.as.empty”=“yes”属性后,此问题得到解决。
--ddl公司