<?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 Hive table doesn't detect input HDFS location because of &amp;quot;_&amp;quot; in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Hive-table-doesn-t-detect-input-HDFS-location-because-of/m-p/91180#M55373</link>
    <description>&lt;P&gt;I have a scenario where i'm trying to create a table which points to an HDFS location which has a directory name starting with an "_" in the HDFS path. Now table creation goes through but If I try to read data out of the table it throws error, below is what i get:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;create external table `ingest.workgroup__views2` row format serde 'org.apache.hadoop.hive.serde2.avro.AvroSerDe' STORED AS INPUTFORMAT 'org.apache.hadoop.hive.ql.io.avro.AvroContainerInputFormat' OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.avro.AvroContainerOutputFormat' location 'hdfs://nameservice1/user/data/ingest/mdm/workgroup_i/workgroup/_views' tblproperties ('avro.schema.url'='hdfs://nameservice1/user/data/ingest/mdm/workgroup_i/workgroup/_views/_gen/_views.avsc');&lt;BR /&gt;No rows affected (0.232 seconds)&lt;BR /&gt;0: jdbc:hive2://t-hive.sys.cigna.com:25006/de&amp;gt; select * from ingest.workgroup__views2;&lt;BR /&gt;Error: java.io.IOException: org.apache.hadoop.mapred.InvalidInputException: Input path does not exist: hdfs://nameservice1/user/data/ingest/mdm/workgroup_i/workgroup/_views (state=,code=0)&lt;BR /&gt;0: jdbc:hive2://t-hive.sys.cigna.com:25006/de&amp;gt; drop table ingest.workgroup__views2;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So i escape the special character "_" in location and the table gets created and i' able to run select to see data as below:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;create external table `ingest.workgroup__views2` row format serde 'org.apache.hadoop.hive.serde2.avro.AvroSerDe' STORED AS INPUTFORMAT 'org.apache.hadoop.hive.ql.io.avro.AvroContainerInputFormat' OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.avro.AvroContainerOutputFormat' location 'hdfs://nameservice1/user/data/ingest/mdm/workgroup_i/workgroup/\_views' tblproperties ('avro.schema.url'='hdfs://nameservice1/user/data/ingest/mdm/workgroup_i/workgroup/_views/_gen/_views.avsc');&lt;BR /&gt;No rows affected (0.19 seconds)&lt;BR /&gt;0: jdbc:hive2://t-hive.sys.cigna.com:25006/de&amp;gt; select * from ingest.workgroup__views2;&lt;BR /&gt;+-----------------------+-------------------------+-----------------------------+-------------------------------+-----------------------------+-------------------------------+--------------------------------+--------------------------+--------------------------+----------------------------+----------------------------+--+&lt;BR /&gt;| workgroup__views2.id | workgroup__views2.name | workgroup__views2.view_url | workgroup__views2.created_at | workgroup__views2.owner_id | workgroup__views2.owner_name | workgroup__views2.workbook_id | workgroup__views2.index | workgroup__views2.title | workgroup__views2.caption | workgroup__views2.site_id |&lt;BR /&gt;+-----------------------+-------------------------+-----------------------------+-------------------------------+-----------------------------+-------------------------------+--------------------------------+--------------------------+--------------------------+----------------------------+----------------------------+--+&lt;BR /&gt;+-----------------------+-------------------------+-----------------------------+-------------------------------+-----------------------------+-------------------------------+--------------------------------+--------------------------+--------------------------+----------------------------+----------------------------+--+&lt;BR /&gt;No rows selected (0.139 seconds)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now the weird part is its only the location part which has this issue, parsing of URI mentioned under tblproperties goes through as you can see above and if I explicitly try to escape "_" in tblproperties it doesn't work.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any comments or suggestions will be helpful on the above obesrvation.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;</description>
    <pubDate>Fri, 16 Sep 2022 14:25:36 GMT</pubDate>
    <dc:creator>Prav</dc:creator>
    <dc:date>2022-09-16T14:25:36Z</dc:date>
    <item>
      <title>Hive table doesn't detect input HDFS location because of "_"</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Hive-table-doesn-t-detect-input-HDFS-location-because-of/m-p/91180#M55373</link>
      <description>&lt;P&gt;I have a scenario where i'm trying to create a table which points to an HDFS location which has a directory name starting with an "_" in the HDFS path. Now table creation goes through but If I try to read data out of the table it throws error, below is what i get:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;create external table `ingest.workgroup__views2` row format serde 'org.apache.hadoop.hive.serde2.avro.AvroSerDe' STORED AS INPUTFORMAT 'org.apache.hadoop.hive.ql.io.avro.AvroContainerInputFormat' OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.avro.AvroContainerOutputFormat' location 'hdfs://nameservice1/user/data/ingest/mdm/workgroup_i/workgroup/_views' tblproperties ('avro.schema.url'='hdfs://nameservice1/user/data/ingest/mdm/workgroup_i/workgroup/_views/_gen/_views.avsc');&lt;BR /&gt;No rows affected (0.232 seconds)&lt;BR /&gt;0: jdbc:hive2://t-hive.sys.cigna.com:25006/de&amp;gt; select * from ingest.workgroup__views2;&lt;BR /&gt;Error: java.io.IOException: org.apache.hadoop.mapred.InvalidInputException: Input path does not exist: hdfs://nameservice1/user/data/ingest/mdm/workgroup_i/workgroup/_views (state=,code=0)&lt;BR /&gt;0: jdbc:hive2://t-hive.sys.cigna.com:25006/de&amp;gt; drop table ingest.workgroup__views2;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So i escape the special character "_" in location and the table gets created and i' able to run select to see data as below:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;create external table `ingest.workgroup__views2` row format serde 'org.apache.hadoop.hive.serde2.avro.AvroSerDe' STORED AS INPUTFORMAT 'org.apache.hadoop.hive.ql.io.avro.AvroContainerInputFormat' OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.avro.AvroContainerOutputFormat' location 'hdfs://nameservice1/user/data/ingest/mdm/workgroup_i/workgroup/\_views' tblproperties ('avro.schema.url'='hdfs://nameservice1/user/data/ingest/mdm/workgroup_i/workgroup/_views/_gen/_views.avsc');&lt;BR /&gt;No rows affected (0.19 seconds)&lt;BR /&gt;0: jdbc:hive2://t-hive.sys.cigna.com:25006/de&amp;gt; select * from ingest.workgroup__views2;&lt;BR /&gt;+-----------------------+-------------------------+-----------------------------+-------------------------------+-----------------------------+-------------------------------+--------------------------------+--------------------------+--------------------------+----------------------------+----------------------------+--+&lt;BR /&gt;| workgroup__views2.id | workgroup__views2.name | workgroup__views2.view_url | workgroup__views2.created_at | workgroup__views2.owner_id | workgroup__views2.owner_name | workgroup__views2.workbook_id | workgroup__views2.index | workgroup__views2.title | workgroup__views2.caption | workgroup__views2.site_id |&lt;BR /&gt;+-----------------------+-------------------------+-----------------------------+-------------------------------+-----------------------------+-------------------------------+--------------------------------+--------------------------+--------------------------+----------------------------+----------------------------+--+&lt;BR /&gt;+-----------------------+-------------------------+-----------------------------+-------------------------------+-----------------------------+-------------------------------+--------------------------------+--------------------------+--------------------------+----------------------------+----------------------------+--+&lt;BR /&gt;No rows selected (0.139 seconds)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now the weird part is its only the location part which has this issue, parsing of URI mentioned under tblproperties goes through as you can see above and if I explicitly try to escape "_" in tblproperties it doesn't work.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any comments or suggestions will be helpful on the above obesrvation.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;</description>
      <pubDate>Fri, 16 Sep 2022 14:25:36 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Hive-table-doesn-t-detect-input-HDFS-location-because-of/m-p/91180#M55373</guid>
      <dc:creator>Prav</dc:creator>
      <dc:date>2022-09-16T14:25:36Z</dc:date>
    </item>
    <item>
      <title>Re: Hive table doesn't detect input HDFS location because of "_"</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Hive-table-doesn-t-detect-input-HDFS-location-because-of/m-p/91250#M55374</link>
      <description>&lt;P&gt;Hey Network,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Anyone had this issue or maybe Cloudera team in this community may share if this a known bug etc?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 05 Jun 2019 14:15:18 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Hive-table-doesn-t-detect-input-HDFS-location-because-of/m-p/91250#M55374</guid>
      <dc:creator>Prav</dc:creator>
      <dc:date>2019-06-05T14:15:18Z</dc:date>
    </item>
    <item>
      <title>Re: Hive table doesn't detect input HDFS location because of "_"</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Hive-table-doesn-t-detect-input-HDFS-location-because-of/m-p/91287#M55375</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/27861"&gt;@Prav&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This appears to have been listed as a bug (which is actually a longstanding limitation due to the definition of files and directories with _ and . being considered as "hidden" in FileInputFormat in Hadoop) of Hive since the 0.12 version:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://issues.apache.org/jira/browse/HIVE-6431" target="_blank" rel="noopener"&gt;https://issues.apache.org/jira/browse/HIVE-6431&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://stackoverflow.com/questions/19830264/which-files-are-ignored-as-input-by-mapper" target="_blank" rel="noopener"&gt;https://stackoverflow.com/questions/19830264/which-files-are-ignored-as-input-by-mapper&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If these files are needed to be seen, please consider using a pre-process script to rename them after loading.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;</description>
      <pubDate>Thu, 06 Jun 2019 16:39:09 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Hive-table-doesn-t-detect-input-HDFS-location-because-of/m-p/91287#M55375</guid>
      <dc:creator>Robert Justice</dc:creator>
      <dc:date>2019-06-06T16:39:09Z</dc:date>
    </item>
  </channel>
</rss>

