thanks
在 2014年08月01日 12:00, Devopam Mittra 写道:
If you have mySQL as your metastore , you may use something similar to
below:
SELECT tbl.TBL_NAME,COUNT(DISTINCT part.PART_NAME) AS partition_count
FROM metastore_db.TBLS tbl, metastore_db.PARTITIONS part
WHERE tbl.TBL_ID = part.TBL_ID
AND tbl.TBL_TYPE = 'MANAGED_TABLE'
GROUP BY tbl.TBL_NAME;
Do remember to change the db name to yours before testing it out :)
regards
Dev
On Thu, Jul 31, 2014 at 6:34 PM, Dan Fan <d...@appnexus.com
<mailto:d...@appnexus.com>> wrote:
The easiest way is to go to hive,
Show create table table_name.
Then you can know when the table, if the it is partitioned
From: Nitin Pawar <nitinpawar...@gmail.com
<mailto:nitinpawar...@gmail.com>>
Reply-To: "user@hive.apache.org <mailto:user@hive.apache.org>"
<user@hive.apache.org <mailto:user@hive.apache.org>>
Date: Thursday, July 31, 2014 at 3:50 AM
To: "user@hive.apache.org <mailto:user@hive.apache.org>"
<user@hive.apache.org <mailto:user@hive.apache.org>>
Subject: Re: How can I know one table is a partitioned table in hive?
what are the options you have?
can you write a java code which can interact with hcatalog ?
or you can do a describle table and check for partion column
details in there
On Thu, Jul 31, 2014 at 1:11 PM, 张甲超 <rebeyond1...@gmail.com
<mailto:rebeyond1...@gmail.com>> wrote:
dear all,
I want know that one table is a partitioned table in
hive, and return the result to shell.
How can I do?
--
Nitin Pawar
--
Devopam Mittra
Life and Relations are not binary