<?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: Handling Dates while copying from Excel to SQL server database table in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359557#M124319</link>
    <description>Will my new job flow be like:&lt;BR /&gt;Excel Input -&amp;gt; tConvertType -&amp;gt; tMap -&amp;gt; tMSSqlOutput ?</description>
    <pubDate>Wed, 28 May 2014 18:22:07 GMT</pubDate>
    <dc:creator>_AnonymousUser</dc:creator>
    <dc:date>2014-05-28T18:22:07Z</dc:date>
    <item>
      <title>Handling Dates while copying from Excel to SQL server database table</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359552#M124314</link>
      <description>Hello, 
&lt;BR /&gt;I am copying data from an Excel workbook to the SQL server database table. 
&lt;BR /&gt;One of the column in my Excel sheet has Dates, which I am generating using Rand function. 
&lt;BR /&gt;If I keep data types of my columns as string in both my Excel input and SQL output. 
&lt;BR /&gt;I get an error which says 
&lt;BR /&gt;"Conversion failed when converting character string to smalldatetime data type." 
&lt;BR /&gt;If I keep my datatypes as Date it gives as error which says 
&lt;BR /&gt;"The cell format is not Date in ....(cell address)" 
&lt;BR /&gt; 
&lt;BR /&gt;In my table's definition in SQL server. It has data type as 'smalldatetime'. 
&lt;BR /&gt;So which data types I should assign to my input as well as output to transfer them from Excel to SQL?</description>
      <pubDate>Sat, 16 Nov 2024 11:37:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359552#M124314</guid>
      <dc:creator>_AnonymousUser</dc:creator>
      <dc:date>2024-11-16T11:37:38Z</dc:date>
    </item>
    <item>
      <title>Re: Handling Dates while copying from Excel to SQL server database table</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359553#M124315</link>
      <description>Hi
&lt;BR /&gt;Can you please upload a screenshot of the source data? It will be helpful for us to understand your problem well.
&lt;BR /&gt;Shong</description>
      <pubDate>Wed, 28 May 2014 16:13:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359553#M124315</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-05-28T16:13:16Z</dc:date>
    </item>
    <item>
      <title>Re: Handling Dates while copying from Excel to SQL server database table</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359554#M124316</link>
      <description>The data is simple dates which I have generated using RANDBETWEEN(...) function.&lt;BR /&gt;It displays as (e.g.1) January 31, 1965 (e.g.2) April 7, 1970... so on.</description>
      <pubDate>Wed, 28 May 2014 16:19:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359554#M124316</guid>
      <dc:creator>_AnonymousUser</dc:creator>
      <dc:date>2014-05-28T16:19:12Z</dc:date>
    </item>
    <item>
      <title>Re: Handling Dates while copying from Excel to SQL server database table</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359555#M124317</link>
      <description>Hi 
&lt;BR /&gt;If you read the data as string, you need to convert the string to Date in the job to map the target data type (smalldatetime). Have a try to add a tLogRow after tFileInputExcel to print the data on the console and see what's data you get from the excel file. 
&lt;BR /&gt;Shong</description>
      <pubDate>Wed, 28 May 2014 16:47:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359555#M124317</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-05-28T16:47:23Z</dc:date>
    </item>
    <item>
      <title>Re: Handling Dates while copying from Excel to SQL server database table</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359556#M124318</link>
      <description>When I remove the mapping between date's columns I am being able to copy the rest of the data.
&lt;BR /&gt;As you have said I need to take Excel input as string, convert it into date format and copy it to the SQL table.
&lt;BR /&gt;Now I wanted to know how and when do I do this?
&lt;BR /&gt;Right now my job has Excel Input (created by metadata -&amp;gt; create file excel) -&amp;gt; tMap -&amp;gt; tMSSqlOutput (created by retrieving the schema from the connection to the database).
&lt;BR /&gt;Where and what changes do I need to make in this job?
&lt;BR /&gt;Thanks,</description>
      <pubDate>Wed, 28 May 2014 18:12:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359556#M124318</guid>
      <dc:creator>_AnonymousUser</dc:creator>
      <dc:date>2014-05-28T18:12:41Z</dc:date>
    </item>
    <item>
      <title>Re: Handling Dates while copying from Excel to SQL server database table</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359557#M124319</link>
      <description>Will my new job flow be like:&lt;BR /&gt;Excel Input -&amp;gt; tConvertType -&amp;gt; tMap -&amp;gt; tMSSqlOutput ?</description>
      <pubDate>Wed, 28 May 2014 18:22:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359557#M124319</guid>
      <dc:creator>_AnonymousUser</dc:creator>
      <dc:date>2014-05-28T18:22:07Z</dc:date>
    </item>
    <item>
      <title>Re: Handling Dates while copying from Excel to SQL server database table</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359558#M124320</link>
      <description>I have tried it but it gives me an error which says &lt;BR /&gt;"java.text.ParseException: Unparseable date: "Fri Nov 30 00:00:00 EST 2001" ?</description>
      <pubDate>Wed, 28 May 2014 18:52:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359558#M124320</guid>
      <dc:creator>_AnonymousUser</dc:creator>
      <dc:date>2014-05-28T18:52:45Z</dc:date>
    </item>
    <item>
      <title>Re: Handling Dates while copying from Excel to SQL server database table</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359559#M124321</link>
      <description>Hi 
&lt;BR /&gt;You don't set the proper date pattern for parsing the data "Fri Nov 30 00:00:00 EST 2001" read by tFileInputExcel from the excel file. You can use the built-in function TalendDate.parseDateLocale() to convert the string data to a Date on tMap. 
&lt;BR /&gt;tFileInputExcel--main--&amp;gt;tMap--&amp;gt;tMSSQLOutput 
&lt;BR /&gt;See my screenshot. 
&lt;BR /&gt;Shong 
&lt;BR /&gt; 
&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009MEGe.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/128441i1B6C4E6329FBB796/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009MEGe.png" alt="0683p000009MEGe.png" /&gt;&lt;/span&gt;</description>
      <pubDate>Thu, 29 May 2014 02:58:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359559#M124321</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-05-29T02:58:48Z</dc:date>
    </item>
    <item>
      <title>Re: Handling Dates while copying from Excel to SQL server database table</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359560#M124322</link>
      <description>I have tried this function but I am still getting errors such as..&lt;BR /&gt;Exception in component tMap_1&lt;BR /&gt;java.lang.NullPointerException&lt;BR /&gt;	at java.text.SimpleDateFormat.parse(Unknown Source)&lt;BR /&gt;	at java.text.DateFormat.parse(Unknown Source)&lt;BR /&gt;	at routines.TalendDate.parseDateLocale(TalendDate.java:854)&lt;BR /&gt;	at datejob2.job1_0_1.Job1.tFileInputExcel_1Process(Job1.java:2177)&lt;BR /&gt;	at datejob2.job1_0_1.Job1.runJobInTOS(Job1.java:2804)&lt;BR /&gt;	at datejob2.job1_0_1.Job1.main(Job1.java:2670)&lt;BR /&gt;&lt;BR /&gt;I wanted to share a screenshot but didn't find the option to do so.</description>
      <pubDate>Thu, 29 May 2014 14:18:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359560#M124322</guid>
      <dc:creator>_AnonymousUser</dc:creator>
      <dc:date>2014-05-29T14:18:01Z</dc:date>
    </item>
    <item>
      <title>Re: Handling Dates while copying from Excel to SQL server database table</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359561#M124323</link>
      <description>before parsing you have to check whether your input column is null or not null. use below statement.&lt;BR /&gt;&lt;PRE&gt;youcolumn!=null &amp;amp;&amp;amp; !"".equalsIgnoreCase(youcolumn)? parsetodate : null&lt;/PRE&gt;</description>
      <pubDate>Thu, 29 May 2014 14:37:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359561#M124323</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-05-29T14:37:22Z</dc:date>
    </item>
    <item>
      <title>Re: Handling Dates while copying from Excel to SQL server database table</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359562#M124324</link>
      <description>Thanks a lot, Umesh!</description>
      <pubDate>Thu, 29 May 2014 15:04:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Handling-Dates-while-copying-from-Excel-to-SQL-server-database/m-p/2359562#M124324</guid>
      <dc:creator>_AnonymousUser</dc:creator>
      <dc:date>2014-05-29T15:04:27Z</dc:date>
    </item>
  </channel>
</rss>

