<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: Hive table with parquet data showing 0 records in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227005#M72569</link>
    <description>&lt;P&gt;hi &lt;A rel="user" href="https://community.cloudera.com/users/14047/karanalang.html" nodeid="14047"&gt;@Karan Alang&lt;/A&gt;, looks like the column ("format") is a reserved word causing the problem, please exclude that from selection and have a try.&lt;/P&gt;</description>
    <pubDate>Tue, 12 Dec 2017 13:47:10 GMT</pubDate>
    <dc:creator>bkosaraju</dc:creator>
    <dc:date>2017-12-12T13:47:10Z</dc:date>
    <item>
      <title>Hive table with parquet data showing 0 records</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227001#M72565</link>
      <description>&lt;P&gt;hello - i've a parquet file, and i've created an EXTERNAL Hive table on top of the parquet file.&lt;/P&gt;&lt;P&gt;When i try to query the table, it give 0 rows, any ideas what the issue might be ?&lt;/P&gt;&lt;PRE&gt;hdfs dfs -ls hdfs://abc/apps/hive/warehouse/amp.db/power/year=2017/month=12/day=01

-rw-r--r-- 2 pstl hdfs141913174 2017-12-01 22:33 hdfs://abc/apps/hive/warehouse/amp.db/power/year=2017/month=12/day=01/part-00023-e749dbd1-63a9-499d-932e-a6eadf03a67c.c000.snappy.parquet&lt;/PRE&gt;&lt;P&gt;Table created :&lt;/P&gt;&lt;PRE&gt;CREATE EXTERNAL TABLE power_k1(topic_k varchar(255), partition_k int, offset_k bigint, timestamp_k timestamp, deviceid bigint,  devicename varchar(50), deviceip varchar(128), peerid int, objectid int,  objectname varchar(256),  objectdesc varchar(256), oid varchar(50),  pduoutlet varchar(50), pluginid int,pluginname varchar(255),  indicatorid int, indicatorname varchar(255),  format int, snmppollvalue varchar(128) COMMENT 'value in sevone kafka avsc',time double,  clustername varchar(50) COMMENT 'rpp or power',  peerip varchar(50))  COMMENT 'external table at /apps/hive/warehouse/amp.db/sevone_power' PARTITIONED BY (  year int,  month int, day int)  STORED AS PARQUET LOCATION '/apps/hive/warehouse/amp.db/power' &lt;/PRE&gt;&lt;P&gt;select count(1) from power_k1 -&amp;gt; returns 0 records&lt;/P&gt;&lt;P&gt;Any ideas what the issue might be &amp;amp; how to debug this ?&lt;/P&gt;</description>
      <pubDate>Tue, 12 Dec 2017 05:43:57 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227001#M72565</guid>
      <dc:creator>karan_alang1</dc:creator>
      <dc:date>2017-12-12T05:43:57Z</dc:date>
    </item>
    <item>
      <title>Re: Hive table with parquet data showing 0 records</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227002#M72566</link>
      <description>&lt;P&gt;Hi &lt;A rel="user" href="https://community.cloudera.com/users/14047/karanalang.html" nodeid="14047"&gt;@Karan Alang&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;For an external Partitioned table, we need to update the partition metadata as the hive will not be aware of these partitions unless the explicitly updated&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;that can be done by either &lt;/P&gt;&lt;PRE&gt;ALTER TABLE power_k1 RECOVER PARTITIONS;
//or
MSCK REPAIR TABLE power_k1;&lt;/PRE&gt;&lt;P&gt;more on this can be found from hive DDL Language Manual.&lt;/P&gt;&lt;P&gt;Hope this helps !!&lt;/P&gt;</description>
      <pubDate>Tue, 12 Dec 2017 06:36:21 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227002#M72566</guid>
      <dc:creator>bkosaraju</dc:creator>
      <dc:date>2017-12-12T06:36:21Z</dc:date>
    </item>
    <item>
      <title>Re: Hive table with parquet data showing 0 records</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227003#M72567</link>
      <description>&lt;P&gt;thanks &lt;A rel="user" href="https://community.cloudera.com/users/15193/bkosaraju.html" nodeid="15193"&gt;@bkosaraju&lt;/A&gt; - that worked !&lt;/P&gt;</description>
      <pubDate>Tue, 12 Dec 2017 06:52:14 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227003#M72567</guid>
      <dc:creator>karan_alang1</dc:creator>
      <dc:date>2017-12-12T06:52:14Z</dc:date>
    </item>
    <item>
      <title>Re: Hive table with parquet data showing 0 records</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227004#M72568</link>
      <description>&lt;A rel="user" href="https://community.cloudera.com/users/15193/bkosaraju.html" nodeid="15193"&gt;@bkosaraju&lt;/A&gt;&lt;P&gt;i'm getting following error in querying the table, any ideas ?&lt;/P&gt;&lt;PRE&gt;0: jdbc:hive2://msc02-jag-hve-002.uat.gdcs.ap&amp;gt; select deviceid, devicename, indicatorname, topic_k, partition_k, offset_k from powerpoll where year=2017 and month=12 and day=11 limit 5;

Error: org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 86.0 failed 4 times, most recent failure: Lost task 0.3 in stage 86.0 (TID 19049, msc02-jag-dn-011.uat.gdcs.apple.com): java.lang.UnsupportedOperationException: org.apache.parquet.column.values.dictionary.PlainValuesDictionary$PlainIntegerDictionaryat org.apache.parquet.column.Dictionary.decodeToLong(Dictionary.java:52)at org.apache.spark.sql.execution.vectorized.OnHeapColumnVector.getLong(OnHeapColumnVector.java:274)at org.apache.spark.sql.catalyst.expressions.GeneratedClass$GeneratedIterator.processNext(Unknown Source)at org.apache.spark.sql.execution.BufferedRowIterator.hasNext(BufferedRowIterator.java:43)at org.apache.spark.sql.execution.WholeStageCodegenExec$$anonfun$8$$anon$1.hasNext(WholeStageCodegenExec.scala:370)at org.apache.spark.sql.execution.SparkPlan$$anonfun$4.apply(SparkPlan.scala:246)at org.apache.spark.sql.execution.SparkPlan$$anonfun$4.apply(SparkPlan.scala:240)at org.apache.spark.rdd.RDD$$anonfun$mapPartitionsInternal$1$$anonfun$apply$24.apply(RDD.scala:803)at org.apache.spark.rdd.RDD$$anonfun$mapPartitionsInternal$1$$anonfun$apply$24.apply(RDD.scala:803)at org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:38)at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:319)at org.apache.spark.rdd.RDD.iterator(RDD.scala:283)at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:70)at org.apache.spark.scheduler.Task.run(Task.scala:86)at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:274)at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)at java.lang.Thread.run(Thread.java:748)&lt;/PRE&gt;</description>
      <pubDate>Tue, 12 Dec 2017 07:42:29 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227004#M72568</guid>
      <dc:creator>karan_alang1</dc:creator>
      <dc:date>2017-12-12T07:42:29Z</dc:date>
    </item>
    <item>
      <title>Re: Hive table with parquet data showing 0 records</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227005#M72569</link>
      <description>&lt;P&gt;hi &lt;A rel="user" href="https://community.cloudera.com/users/14047/karanalang.html" nodeid="14047"&gt;@Karan Alang&lt;/A&gt;, looks like the column ("format") is a reserved word causing the problem, please exclude that from selection and have a try.&lt;/P&gt;</description>
      <pubDate>Tue, 12 Dec 2017 13:47:10 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227005#M72569</guid>
      <dc:creator>bkosaraju</dc:creator>
      <dc:date>2017-12-12T13:47:10Z</dc:date>
    </item>
    <item>
      <title>Re: Hive table with parquet data showing 0 records</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227006#M72570</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/15193/bkosaraju.html" nodeid="15193"&gt;@bkosaraju&lt;/A&gt; - this is the query fired .. &lt;/P&gt;&lt;PRE&gt;select deviceid, devicename, indicatorname, topic_k, partition_k, offset_k from powerpoll where year=2017 and month=12 and day=11 limit 5;&lt;/PRE&gt;&lt;P&gt;There is no column called format, can you pls. clarify what you meant ? &lt;/P&gt;</description>
      <pubDate>Tue, 12 Dec 2017 14:54:08 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227006#M72570</guid>
      <dc:creator>karan_alang1</dc:creator>
      <dc:date>2017-12-12T14:54:08Z</dc:date>
    </item>
    <item>
      <title>Re: Hive table with parquet data showing 0 records</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227007#M72571</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/15193/bkosaraju.html" nodeid="15193"&gt;@bkosaraju&lt;/A&gt; - .. i re-checked this &amp;amp; the issue seems to be when i include the column - deviceid bigint - in the query &lt;/P&gt;</description>
      <pubDate>Tue, 12 Dec 2017 15:23:30 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hive-table-with-parquet-data-showing-0-records/m-p/227007#M72571</guid>
      <dc:creator>karan_alang1</dc:creator>
      <dc:date>2017-12-12T15:23:30Z</dc:date>
    </item>
  </channel>
</rss>

