<?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>topic Re: [resolved] Talend _Vertica_Bulk Load - String _Date handling in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/resolved-Talend-Vertica-Bulk-Load-String-Date-handling/m-p/2357119#M122495</link>
    <description>try this:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE&gt;(row2.d1=null||row2.d1.equals("") ||row2.d1.length()==0)? null :TalendDate.parseDate("MM-dd-yyyy",row2.d1)&amp;nbsp;&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;You can read function descriptions in tMap&amp;nbsp;&lt;BR /&gt;for the TalendDate.parseDate - yyyyMMdd is expected pattern of source string</description>
    <pubDate>Tue, 28 Mar 2017 00:59:01 GMT</pubDate>
    <dc:creator>vapukov</dc:creator>
    <dc:date>2017-03-28T00:59:01Z</dc:date>
    <item>
      <title>[resolved] Talend _Vertica_Bulk Load - String _Date handling</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Talend-Vertica-Bulk-Load-String-Date-handling/m-p/2357118#M122494</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;while try to load the below data using tVerticaoutputbulkexec, &amp;nbsp;record 3, with null values for d1 date column is getting rejected.&lt;BR /&gt;ID|d1|d2|Val&lt;BR /&gt;1|20071231|20071226|dt&lt;BR /&gt;2|20070302|20171226|dt&lt;BR /&gt;3||20171231|dt3&lt;BR /&gt;Output:&lt;BR /&gt;[statistics] connected&lt;BR /&gt;1|12-31-2007|12-26-2007|8&lt;BR /&gt;2|03-02-2007|12-26-2017|8&lt;BR /&gt;3||12-31-2017|0&lt;BR /&gt;&lt;STRONG&gt;Number of records inserted into table hls_others.test_Date by tVerticaOutputBulkExec_2_tVBE: 2&lt;/STRONG&gt;&lt;BR /&gt;[statistics] disconnected&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;Error :&lt;/STRONG&gt;&lt;BR /&gt;COPY: Input record 3 has been rejected (Invalid date format '' for column 2 (d1).Invalid input syntax for date: ""). &amp;nbsp;Please see /Out/TestDate_Rej.dlm, record 1 for the rejected record. This record was read from STDIN&lt;BR /&gt;i am using below logic to handle null but still this record is getting error out&lt;BR /&gt;(row2.d1.equals(null)||row2.d1.equals("") ||row2.d1.length()==0)? null :&lt;BR /&gt;TalendDate.parseDate("yyyyMMdd",row2.d1)&amp;nbsp;&lt;BR /&gt;to avoid this, i am handling null &amp;nbsp;and still it is throwing an error.&lt;BR /&gt;&amp;nbsp;Mapping Design&lt;BR /&gt;&lt;IMG src="https://community.talend.com/legacyfs/online/395438/blob.png" border="0" /&gt;&lt;BR /&gt;mapping&amp;nbsp;&lt;BR /&gt;(row2.d1.equals(null)||row2.d1.equals("") ||row2.d1.length()==0)? null :&lt;BR /&gt;TalendDate.parseDate("yyyyMMdd",row2.d1)&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pl Advise how to handle this situation ?&lt;/P&gt;</description>
      <pubDate>Mon, 27 Mar 2017 23:47:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Talend-Vertica-Bulk-Load-String-Date-handling/m-p/2357118#M122494</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-03-27T23:47:10Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Talend _Vertica_Bulk Load - String _Date handling</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Talend-Vertica-Bulk-Load-String-Date-handling/m-p/2357119#M122495</link>
      <description>try this:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE&gt;(row2.d1=null||row2.d1.equals("") ||row2.d1.length()==0)? null :TalendDate.parseDate("MM-dd-yyyy",row2.d1)&amp;nbsp;&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;You can read function descriptions in tMap&amp;nbsp;&lt;BR /&gt;for the TalendDate.parseDate - yyyyMMdd is expected pattern of source string</description>
      <pubDate>Tue, 28 Mar 2017 00:59:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Talend-Vertica-Bulk-Load-String-Date-handling/m-p/2357119#M122495</guid>
      <dc:creator>vapukov</dc:creator>
      <dc:date>2017-03-28T00:59:01Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Talend _Vertica_Bulk Load - String _Date handling</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Talend-Vertica-Bulk-Load-String-Date-handling/m-p/2357120#M122496</link>
      <description>the issue is due to null; verticabulkload&amp;nbsp; is using copy table STDIN &amp;lt;path&amp;gt; and if the column Is null then it is getting rejected to error file.&lt;BR /&gt;resolved with following workaround.&lt;BR /&gt;TalendDate.isDate(row1.d1,"yyyyMMdd")?TalendDate.parseDate("yyyyMMdd",row1.d1):TalendDate.parseDate("yyyyMMdd","99991231")&lt;BR /&gt;But i am eager to hear from our community for the solution " how to populate nulls for date columns while using verticabulkloadexe ".</description>
      <pubDate>Tue, 28 Mar 2017 05:10:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Talend-Vertica-Bulk-Load-String-Date-handling/m-p/2357120#M122496</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-03-28T05:10:04Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Talend _Vertica_Bulk Load - String _Date handling</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Talend-Vertica-Bulk-Load-String-Date-handling/m-p/2357121#M122497</link>
      <description>I was able to load and handle the null values for dates column. Its my understanding issue on the property settings in VerticaBulkExec.
&lt;BR /&gt;
&lt;BR /&gt;Here is the answer for loading null values for date columns in Vertica using tVerticaBulkExec component.&amp;nbsp;
&lt;BR /&gt;To check the input column and assign the null values.[ there is many way to check and assign. couple of options is here]&amp;nbsp;
&lt;BR /&gt;TalendDate.isDate(row1.d2,"yyyyMMdd")?TalendDate.parseDate("yyyyMMdd",row1.d2):null&amp;nbsp;
&lt;BR /&gt;or&amp;nbsp;
&lt;FONT size="2"&gt;&lt;FONT face="consolas," monaco=""&gt;row2.d1=null||row2.d1.equals("") ||row2.d1.length()==0)? null :TalendDate.parseDate("MM-dd-yyyy",row2.d1) or &lt;/FONT&gt;&lt;/FONT&gt;
&lt;BR /&gt;[font=consolas, monaco, bitstream vera sans mono, courier new, courier, monospace]
&lt;FONT size="2"&gt;(!Relational.ISNULL(row1.d1) &amp;amp;&amp;amp;&lt;BR /&gt;!"".equalsIgnoreCase(row1.d1) )? TalendDate.parseDate("yyyyMMdd",row1.d1): null &lt;/FONT&gt;[/font]
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;[font=consolas, monaco, bitstream vera sans mono, courier new, courier, monospace]
&lt;FONT size="2"&gt;this will give an empty string for null columns. and you should handle this in advanced setting Null String "". &lt;/FONT&gt;[/font]
&lt;BR /&gt;[font=consolas, monaco, bitstream vera sans mono, courier new, courier, monospace]
&lt;FONT size="2"&gt;Default value for this setting is "null"&lt;/FONT&gt;[/font]
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;IMG src="https://community.talend.com/legacyfs/online/395438/blob_20170328-1419.png" /&gt;
&lt;BR /&gt;
&lt;BR /&gt;Thanks&amp;nbsp;</description>
      <pubDate>Tue, 28 Mar 2017 22:24:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Talend-Vertica-Bulk-Load-String-Date-handling/m-p/2357121#M122497</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-03-28T22:24:16Z</dc:date>
    </item>
  </channel>
</rss>

