Hive Avro to Parquet table conversion
- 主要言語
- Java
- スター
- 3.1k
- フォーク
- 1.6k
- 平均マージ
- 3日 12時間
- マージ済み PR(30日)
- 33
説明
Hi.
I have following avro schema
```Java
{
"namespace" : "com.example.test",
"type" : "record",
"name" : "TestRecord",
"fields" : [{"name" : "objectLink", "type" : [
{"type": "record", "name" : "TestObj1", "fields" : [{"name":"obj1VisitorId","type":["null","string"]}] },
{"type": "record", "name" : "TestObj2", "fields" : [{"name":"obj2VisitorId","type":["null","string"]}]}
]
}],
"doc" : "event for test purposes"
}
```
Using this schema I can create avro objects, also I'm able to create table backed by avro in Hive. But then I want to create a table backed by parquet I'm doing
CREATE TABLE parquet_table
STORED AS parquet
AS SELECT \* FROM avro_table
and i get
SemanticException java.lang.UnsupportedOperationException: Unknown field type: uniontype,struct>
Is there a way to convert such structures, to store them in hive backed as parquet? This is a simple example, but I have big data structure described in avro, so I can't convert it manually, and also I have data which already stored in avro and need to be loaded in table, backed by parquet. Is there any way to this?
I'm using hive 0.13.
**Reporter**: [Dmitriy](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=dimaga) / @dimaga
**Note**: *This issue was originally created as [PARQUET-155](https://issues.apache.org/jira/browse/PARQUET-155). Please see the [migration documentation](https://issues.apache.org/jira/browse/PARQUET-2502) for further details.*
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
調査の方向性
参照されている移行ドキュメントを読み、ネストされた union スキーマを使用して Hive 0.13 CREATE TABLE parquet_table STORED AS parquet AS SELECT * FROM avro_table クエリを再現してください。報告されている Unknown field type: uniontype エラーを出発点とし、この構造を Parquet に変換するための文書化または実装されたパスが用意されていれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 領域
- databases
- issue の種類
- バグ
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 活発さ
- 停滞
- 明瞭さ
- 説明が足りない
- 初心者へのやさしさ
- 20/100