<?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] Rollback entire transaction in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329004#M98226</link>
    <description>Hi,
&lt;BR /&gt;Here's a suggestion of what you could do:
&lt;BR /&gt;1. Wire the Rejects link from each of the tOracleOutput to the OracleFile.
&lt;BR /&gt;2. Have a PostJob flow as the following:
&lt;BR /&gt;tPostJob ---onComponentOk--&amp;gt; tJava ----- if (number of lines in OracleFile &amp;gt; 0) ----&amp;gt; tOracleRollBack
&lt;BR /&gt; ----- if (number of lines in OracleFile &amp;lt;= 0) -----&amp;gt; tCommit
&lt;BR /&gt;Note: You can get the number of lines in OracleFile through the following: ((Integer)globalMap.get("tFileOutputDelimited_1_NB_LINE")).intValue()
&lt;BR /&gt;Hope this helps!
&lt;BR /&gt;Regards,
&lt;BR /&gt;Serpico</description>
    <pubDate>Wed, 03 Feb 2010 16:08:37 GMT</pubDate>
    <dc:creator>Serpico</dc:creator>
    <dc:date>2010-02-03T16:08:37Z</dc:date>
    <item>
      <title>[resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329003#M98225</link>
      <description>Hi,
&lt;BR /&gt;I have delimited file, mapped via tMap to 4 different Oracle output tables. If there is an error record in any of the records, I need the entire transaction to be rolled back. And I also want all the records that were rejected to be in the Oracle File.
&lt;BR /&gt;Here's what I have so far:
&lt;BR /&gt;tOracleConnection--&amp;gt;onSubjobOK--&amp;gt;tFileInputDelimited--&amp;gt;tMap--&amp;gt;OracleOutput1--&amp;gt;??????
&lt;BR /&gt;If I have 5 records, and 2 were rejected, while 3 were good, how do I rollback the entire thing?
&lt;BR /&gt;Records can be rejected for variety of reasons: formatting issues, or b/c they already exist in the database...
&lt;BR /&gt;I put tRollback after tOracleOutput, but not sure how to specify a condition.
&lt;BR /&gt;Thanks,
&lt;BR /&gt;Boris</description>
      <pubDate>Sat, 16 Nov 2024 13:34:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329003#M98225</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-11-16T13:34:32Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329004#M98226</link>
      <description>Hi,
&lt;BR /&gt;Here's a suggestion of what you could do:
&lt;BR /&gt;1. Wire the Rejects link from each of the tOracleOutput to the OracleFile.
&lt;BR /&gt;2. Have a PostJob flow as the following:
&lt;BR /&gt;tPostJob ---onComponentOk--&amp;gt; tJava ----- if (number of lines in OracleFile &amp;gt; 0) ----&amp;gt; tOracleRollBack
&lt;BR /&gt; ----- if (number of lines in OracleFile &amp;lt;= 0) -----&amp;gt; tCommit
&lt;BR /&gt;Note: You can get the number of lines in OracleFile through the following: ((Integer)globalMap.get("tFileOutputDelimited_1_NB_LINE")).intValue()
&lt;BR /&gt;Hope this helps!
&lt;BR /&gt;Regards,
&lt;BR /&gt;Serpico</description>
      <pubDate>Wed, 03 Feb 2010 16:08:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329004#M98226</guid>
      <dc:creator>Serpico</dc:creator>
      <dc:date>2010-02-03T16:08:37Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329005#M98227</link>
      <description>I tried without tJava by doing the following:&lt;BR /&gt;tOracleOutput--&amp;gt;Rejects--&amp;gt;tFileOutputDelimited--&amp;gt;runIf--&amp;gt;tOracleRollback.&lt;BR /&gt;in runIf I specified a condition: ((Integer)globalMap.get("tFileOutputDelimited_1_NB_LINE")) &amp;gt; 0&lt;BR /&gt;When I run it, it checks runif, marks it as True, but does not rollback the other records, that were inserted.</description>
      <pubDate>Wed, 03 Feb 2010 17:11:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329005#M98227</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-02-03T17:11:41Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329006#M98228</link>
      <description>You might want to increase the "commit every" field in the tOracleOutput.</description>
      <pubDate>Wed, 03 Feb 2010 18:06:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329006#M98228</guid>
      <dc:creator>Serpico</dc:creator>
      <dc:date>2010-02-03T18:06:15Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329007#M98229</link>
      <description>Makre sure the "Auto Commit" in your tOracleConnection is unchecked.</description>
      <pubDate>Wed, 03 Feb 2010 18:27:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329007#M98229</guid>
      <dc:creator>Serpico</dc:creator>
      <dc:date>2010-02-03T18:27:27Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329008#M98230</link>
      <description>i have it set to 10000.&lt;BR /&gt;and I am only processing three test records as of now.</description>
      <pubDate>Wed, 03 Feb 2010 18:28:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329008#M98230</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-02-03T18:28:49Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329009#M98231</link>
      <description>auto commit is unchecked.&lt;BR /&gt;What else could it be?</description>
      <pubDate>Wed, 03 Feb 2010 18:36:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329009#M98231</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-02-03T18:36:51Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329010#M98232</link>
      <description>Make sure then you "use an existing connection" in your tOracleOutput.</description>
      <pubDate>Wed, 03 Feb 2010 18:39:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329010#M98232</guid>
      <dc:creator>Serpico</dc:creator>
      <dc:date>2010-02-03T18:39:46Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329011#M98233</link>
      <description>Serpico,
&lt;BR /&gt;That was it!!! use existing connection box had to be checked. 
&lt;BR /&gt;Thanks for figuring this out.
&lt;BR /&gt;I will go and try to put all of this in PostJob and Prejob.
&lt;BR /&gt;Thanks again, I really appreciate this.</description>
      <pubDate>Wed, 03 Feb 2010 19:03:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329011#M98233</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-02-03T19:03:11Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329012#M98234</link>
      <description>Do I need to put any code into tJava, or just into RunIf connectors?</description>
      <pubDate>Wed, 03 Feb 2010 19:29:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329012#M98234</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-02-03T19:29:44Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329013#M98235</link>
      <description>No need to put any code in tJava. I usually put this component as a pre-step to use the RunIf connectors.</description>
      <pubDate>Wed, 03 Feb 2010 19:32:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329013#M98235</guid>
      <dc:creator>Serpico</dc:creator>
      <dc:date>2010-02-03T19:32:22Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329014#M98236</link>
      <description>So for two outputs, I specify:&lt;BR /&gt;((Integer)globalMap.get("tFileOutputDelimited_1_NB_LINE")) &amp;lt;= 0 &amp;amp;&amp;amp;&lt;BR /&gt;((Integer)globalMap.get("tFileOutputDelimited_2_NB_LINE")) &amp;lt;= 0&lt;BR /&gt;in the RunIf connector and get an error.&lt;BR /&gt;Is this not the correct way?</description>
      <pubDate>Wed, 03 Feb 2010 19:48:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329014#M98236</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-02-03T19:48:43Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329015#M98237</link>
      <description>i guess this is correct: ((Integer)globalMap.get("tFileOutputDelimited_1_NB_LINE")+(Integer)globalMap.get("tFileOutputDelimited_2_NB_LINE")) &amp;lt;= 0</description>
      <pubDate>Wed, 03 Feb 2010 19:51:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329015#M98237</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-02-03T19:51:41Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Rollback entire transaction</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329016#M98238</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;((Integer)globalMap.get("tFileOutputDelimited_1_NB_LINE")) &amp;lt;= 0 &amp;amp;&amp;amp;&lt;BR /&gt;((Integer)globalMap.get("tFileOutputDelimited_2_NB_LINE")) &amp;lt;= 0&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;The above condition will call the Commit if it is true.&lt;BR /&gt;On the opposite, the following condition will call the RollBack if it is true:&lt;BR /&gt;&lt;PRE&gt;((Integer)globalMap.get("tFileOutputDelimited_1_NB_LINE")) &amp;gt; 0 ||&lt;BR /&gt;((Integer)globalMap.get("tFileOutputDelimited_2_NB_LINE")) &amp;gt; 0&lt;/PRE&gt;</description>
      <pubDate>Wed, 03 Feb 2010 19:55:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Rollback-entire-transaction/m-p/2329016#M98238</guid>
      <dc:creator>Serpico</dc:creator>
      <dc:date>2010-02-03T19:55:49Z</dc:date>
    </item>
  </channel>
</rss>

