<?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 Nifi - how to run a simple standalone INSERT SQL statement in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Nifi-how-to-run-a-simple-standalone-INSERT-SQL-statement/m-p/335915#M232063</link>
    <description>&lt;P&gt;Hello Experts,&lt;/P&gt;&lt;P&gt;&amp;nbsp;I want to run a simple Hive Insert SQL statement in Nifi periodically for example:&lt;/P&gt;&lt;P&gt;&lt;EM&gt;insert overwrite Table1 select * from Table2;&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;All SQL values are fixed hardcoded and don't need to be changed dynamically in the flow. As a newbie I was thinking I could write the flow as:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;ReplaceText-&amp;gt;success-&amp;gt;PutHiveQL&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class="slick-cell l0 r0 selected active"&gt;&lt;SPAN class="table-cell required"&gt;Search Value:&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;(?s)(^.*$)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 selected active"&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&lt;SPAN class="table-cell required"&gt;Replacement Value:&amp;nbsp;&amp;nbsp;&lt;EM&gt;insert overwrite Table1 select * from Table2;&amp;nbsp;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&lt;SPAN class="table-cell required"&gt;But I have an error in ReplaceText which probably needs an incoming flowfile which I don't have since the SQL is fixed hardcoded:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&lt;SPAN class="table-cell required"&gt;"Upstream Connections is invalid because Processor requires an upstream connection but currently has none."&amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;The other option I could try but not sure it will work is:&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&lt;P&gt;GenerateFlowFile -&amp;gt; success -&amp;gt; PutHiveQL&lt;/P&gt;&lt;P&gt;GenerateFlowFile Custom Text: insert overwrite Table1 select * from Table2;&lt;/P&gt;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 10 Feb 2022 03:52:28 GMT</pubDate>
    <dc:creator>ebeb</dc:creator>
    <dc:date>2022-02-10T03:52:28Z</dc:date>
    <item>
      <title>Nifi - how to run a simple standalone INSERT SQL statement</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-how-to-run-a-simple-standalone-INSERT-SQL-statement/m-p/335915#M232063</link>
      <description>&lt;P&gt;Hello Experts,&lt;/P&gt;&lt;P&gt;&amp;nbsp;I want to run a simple Hive Insert SQL statement in Nifi periodically for example:&lt;/P&gt;&lt;P&gt;&lt;EM&gt;insert overwrite Table1 select * from Table2;&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;All SQL values are fixed hardcoded and don't need to be changed dynamically in the flow. As a newbie I was thinking I could write the flow as:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;ReplaceText-&amp;gt;success-&amp;gt;PutHiveQL&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class="slick-cell l0 r0 selected active"&gt;&lt;SPAN class="table-cell required"&gt;Search Value:&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;(?s)(^.*$)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 selected active"&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&lt;SPAN class="table-cell required"&gt;Replacement Value:&amp;nbsp;&amp;nbsp;&lt;EM&gt;insert overwrite Table1 select * from Table2;&amp;nbsp;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&lt;SPAN class="table-cell required"&gt;But I have an error in ReplaceText which probably needs an incoming flowfile which I don't have since the SQL is fixed hardcoded:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&lt;SPAN class="table-cell required"&gt;"Upstream Connections is invalid because Processor requires an upstream connection but currently has none."&amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;The other option I could try but not sure it will work is:&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&lt;P&gt;GenerateFlowFile -&amp;gt; success -&amp;gt; PutHiveQL&lt;/P&gt;&lt;P&gt;GenerateFlowFile Custom Text: insert overwrite Table1 select * from Table2;&lt;/P&gt;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="slick-cell l0 r0 active selected"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 10 Feb 2022 03:52:28 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-how-to-run-a-simple-standalone-INSERT-SQL-statement/m-p/335915#M232063</guid>
      <dc:creator>ebeb</dc:creator>
      <dc:date>2022-02-10T03:52:28Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi - how to run a simple standalone CTAS SQL statement</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-how-to-run-a-simple-standalone-INSERT-SQL-statement/m-p/335948#M232071</link>
      <description>&lt;P&gt;The alternative your mentioned of using GenerateFlow file is the way to go here.&lt;/P&gt;</description>
      <pubDate>Thu, 10 Feb 2022 03:49:07 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-how-to-run-a-simple-standalone-INSERT-SQL-statement/m-p/335948#M232071</guid>
      <dc:creator>araujo</dc:creator>
      <dc:date>2022-02-10T03:49:07Z</dc:date>
    </item>
  </channel>
</rss>

