<?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: SQOOP IMPORT --map-column-hive ignored in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/SQOOP-IMPORT-map-column-hive-ignored/m-p/62297#M45643</link>
    <description>&lt;P&gt;Hi kerjo,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was facing the same issue with &lt;EM&gt;map-column-java&lt;/EM&gt; and &lt;EM&gt;map-column-hive&lt;/EM&gt; while importing date/timestamp column from Oracle RDBMS to Hive parquet table using Sqoop. My Hive column is of type string.&lt;/P&gt;&lt;P&gt;Version CDH 5.12.1, Parquet 1.5.0.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;A partial workaround I discovered is to convert the Date column to string using a &lt;STRONG&gt;free form query&lt;/STRONG&gt; in Sqoop.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Input column in oracle (type Date):&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;'16.11.2017 09:44:11'&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;--query&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;select t.trans_id, to_char(t.trans_date_sysdate) trans_date_char from test_table_1 t where $CONDITIONS&lt;/PRE&gt;&lt;P&gt;Result in Hive looks like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class="editorComponents notebook"&gt;16-NOV-17&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class="editorComponents notebook"&gt;Unfortunately, this is not enough, I am still not able to import the HH:mm:SS part. &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 28 Nov 2017 14:23:28 GMT</pubDate>
    <dc:creator>AlexMulti</dc:creator>
    <dc:date>2017-11-28T14:23:28Z</dc:date>
  </channel>
</rss>

