Hive:如何显示表的所有分区? [英] Hive: how to show all partitions of a table?

查看:430
本文介绍了Hive:如何显示表的所有分区?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一张有1000多个分区的桌子。



显示分区命令仅列出少量分区。



如何显示所有分区?

更新:


  1. 我发现 show partitions 命令只列出了500个分区。

  2. select ... where ... 仅处理500个分区!



解决方案

当显示输出时,CLI有一些限制。我建议将输出导出到本地文件中:

  $ hive -e'show partitions table;'>分区


I have a table with 1000+ partitions.

"Show partitions" command only lists a small number of partitions.

How can i show all partitions?

Update:

  1. I found "show partitions" command only lists exactly 500 partitions.

  2. "select ... where ..." only processes the 500 partitions!

解决方案

CLI has some limit when ouput is displayed. I suggest to export output into local file:

$hive -e 'show partitions table;' > partitions

这篇关于Hive:如何显示表的所有分区?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆