问题描述
使用sqoop我可以创建托管表,但不能创建外部表。
请让我知道从数据仓库中卸载数据并将其加载的最佳实践Hive外部表。
1.仓库中的表是分区的。一些是明智的分区,一些是明智的分区。
请在生产环境中使用您的想法或做法。
Sqoop不支持创建Hive外部表。相反,您可以:使用Sqoop codegen命令生成用于创建与远程RDBMS表相匹配的Hive内部表的SQL(请参阅 a href =http://sqoop.apache.org/docs/1.4.2/SqoopUserGuide.html#_literal_sqoop_codegen_literal =nofollow> http://sqoop.apache.org/docs/1.4.2/SqoopUserGuide。
Using sqoop I can create managed table but not the externale table.
Please let me know what are the best practices to unload data from data warehouse and load them in Hive external table.
1.The tables in warehouse are partitioned. Some are date wise partitioned some are state wise partitioned.
Please put your thoughts or practices used in production environment.
Sqoop does not support creating Hive external tables. Instead you might:
- Use the Sqoop codegen command to generate the SQL for creating the Hive internal table that matches your remote RDBMS table (see http://sqoop.apache.org/docs/1.4.2/SqoopUserGuide.html#_literal_sqoop_codegen_literal)
- Modify the generated SQL to create a Hive external table
- Execute the modified SQL in Hive
- Run your Sqoop import command, loading into the pre-created Hive external table
这篇关于如何使用sqoop在Hive中创建外部表。需要建议的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!