<?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: Fail to insert long number into AS400 in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/Fail-to-insert-long-number-into-AS400/m-p/2203264#M4643</link>
    <description>I've just tried with a tFixedFlowInput with only one column (which contain my "2500000000" long number) connected to the AS400Output : same error !
&lt;BR /&gt;I think it's a jdbc driver issue</description>
    <pubDate>Wed, 17 Dec 2008 16:27:48 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2008-12-17T16:27:48Z</dc:date>
    <item>
      <title>Fail to insert long number into AS400</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Fail-to-insert-long-number-into-AS400/m-p/2203263#M4642</link>
      <description>Hi, 
&lt;BR /&gt;
&lt;BR /&gt;Very easy to reproduce, I simply have a tFileInputPositional linked to an AS400Output with same schema (use the sync button in order to be sure, and I've done a double-check !)
&lt;BR /&gt;In the tFileInputPositional, I've got a big number field.
&lt;BR /&gt;
&lt;BR /&gt;*If i try to set it as Integer : 
&lt;BR /&gt;For input string: "000002500000000"
&lt;BR /&gt;For input string: "000002500000000"
&lt;BR /&gt;For input string: "000003125000000"
&lt;BR /&gt;For input string: "000007562500000"
&lt;BR /&gt;For input string: "000002500000000"
&lt;BR /&gt;For input string: "000002500000000"
&lt;BR /&gt;For input string: "000003125000000"
&lt;BR /&gt;For input string: "000007562500000"
&lt;BR /&gt;As expected, because my number is too large for an integer... (by the way, is there a way to have the full stack trace instead of this very short message ? The full message should be "NumberFormatException For input string blah blah")
&lt;BR /&gt;*But if I set it as Long : 
&lt;BR /&gt;Exception in component tAS400Output_1
&lt;BR /&gt;java.sql.DataTruncation: Data truncation
&lt;BR /&gt; at com.ibm.as400.access.AS400JDBCPreparedStatement.testDataTruncation(AS400JDBCPreparedStatement.java:3040)
&lt;BR /&gt; at com.ibm.as400.access.AS400JDBCPreparedStatement.setValue(AS400JDBCPreparedStatement.java:2951)
&lt;BR /&gt; at com.ibm.as400.access.AS400JDBCPreparedStatement.setLong(AS400JDBCPreparedStatement.java:2323)
&lt;BR /&gt; at test.testnombre2_0_1.TestNombre2.tFileInputPositional_1Process(TestNombre2.java:2580)
&lt;BR /&gt; at test.testnombre2_0_1.TestNombre2.runJobInTOS(TestNombre2.java:2969)
&lt;BR /&gt; at test.testnombre2_0_1.TestNombre2.main(TestNombre2.java:2882)
&lt;BR /&gt;Yes, this time it's the AS400Output component which is complaining...
&lt;BR /&gt;
&lt;BR /&gt;*And eventually if I set my field as String, it works fine (but I want a Long column, not varchar !)
&lt;BR /&gt;How could you explain that ?
&lt;BR /&gt;Thank you
&lt;BR /&gt;
&lt;BR /&gt;edit : maybe there's a link between this strange behaviour and my previous post about strange character at the begining of my inserted fields.
&lt;BR /&gt;Maybe the AS400 jdbc driver try to add the -now well known- extra character in front of my number ? A lot of maybe... :+)</description>
      <pubDate>Sat, 16 Nov 2024 14:07:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Fail-to-insert-long-number-into-AS400/m-p/2203263#M4642</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-11-16T14:07:11Z</dc:date>
    </item>
    <item>
      <title>Re: Fail to insert long number into AS400</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Fail-to-insert-long-number-into-AS400/m-p/2203264#M4643</link>
      <description>I've just tried with a tFixedFlowInput with only one column (which contain my "2500000000" long number) connected to the AS400Output : same error !
&lt;BR /&gt;I think it's a jdbc driver issue</description>
      <pubDate>Wed, 17 Dec 2008 16:27:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Fail-to-insert-long-number-into-AS400/m-p/2203264#M4643</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-12-17T16:27:48Z</dc:date>
    </item>
    <item>
      <title>Re: Fail to insert long number into AS400</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Fail-to-insert-long-number-into-AS400/m-p/2203265#M4644</link>
      <description>Hi,
&lt;BR /&gt;Did you verify your column length in your DB schema? It should be greater than 10 to hold your number "2500000000".
&lt;BR /&gt;Regards,
&lt;BR /&gt;Youssef</description>
      <pubDate>Wed, 17 Dec 2008 16:33:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Fail-to-insert-long-number-into-AS400/m-p/2203265#M4644</guid>
      <dc:creator>youssef2</dc:creator>
      <dc:date>2008-12-17T16:33:29Z</dc:date>
    </item>
    <item>
      <title>Re: Fail to insert long number into AS400</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Fail-to-insert-long-number-into-AS400/m-p/2203266#M4645</link>
      <description>&lt;BLOCKQUOTE&gt; 
 &lt;TABLE border="1"&gt; 
  &lt;TBODY&gt; 
   &lt;TR&gt; 
    &lt;TD&gt;Hi,&lt;BR /&gt;Did you verify your column length in your DB schema? It should be greater than 10 to hold your number "2500000000".&lt;BR /&gt;Regards,&lt;BR /&gt;Youssef&lt;/TD&gt; 
   &lt;/TR&gt; 
  &lt;/TBODY&gt; 
 &lt;/TABLE&gt; 
&lt;/BLOCKQUOTE&gt; 
&lt;BR /&gt;Yes, my column length is 15 characters on both side. Moreover, the AS400Output is set with "Drop table if exist then create" option</description>
      <pubDate>Wed, 17 Dec 2008 16:36:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Fail-to-insert-long-number-into-AS400/m-p/2203266#M4645</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-12-17T16:36:12Z</dc:date>
    </item>
    <item>
      <title>Re: Fail to insert long number into AS400</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Fail-to-insert-long-number-into-AS400/m-p/2203267#M4646</link>
      <description>Shame on me, it seems that long type in db is not the same that long type in java/c/c++, etc 
&lt;BR /&gt;I set my field as "BigDecimal" on both side and it seems to work. 
&lt;BR /&gt;Anyone to confirm that "long" in db world is not "long" in java world ? 
&lt;BR /&gt;thanks ! 
&lt;BR /&gt;edit : according to this website ( 
&lt;A href="http://www.ss64.com/orasyntax/datatypes.html" rel="nofollow noopener noreferrer"&gt;http://www.ss64.com/orasyntax/datatypes.html&lt;/A&gt; ) a LONG is "Character data of variable length (A bigger version the VARCHAR2 datatype)" 
&lt;BR /&gt;so, sorry for these messages 
&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009MACn.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/154443iC5B8CACEF3D12C6A/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009MACn.png" alt="0683p000009MACn.png" /&gt;&lt;/span&gt;</description>
      <pubDate>Wed, 17 Dec 2008 16:45:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Fail-to-insert-long-number-into-AS400/m-p/2203267#M4646</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-12-17T16:45:16Z</dc:date>
    </item>
  </channel>
</rss>

