<?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 Store intermediate Query Result to variable in Beeline-Hive in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Store-intermediate-Query-Result-to-variable-in-Beeline-Hive/m-p/277389#M207546</link>
    <description>&lt;P&gt;Is there a way to store intermediate query results in&amp;nbsp;Beeline - Hive&lt;/P&gt;&lt;P&gt;something like below in pseudo code. within a beeline session&lt;/P&gt;&lt;P&gt;beeline -u&amp;nbsp; -e"&lt;/P&gt;&lt;P&gt;&amp;nbsp;set var1 = select max(date) from tableA;&lt;/P&gt;&lt;P&gt;&amp;nbsp;set var2 = select count(emps) from tableB;&lt;/P&gt;&lt;P&gt;set var3 = select min(date) from tableC;&lt;/P&gt;&lt;P&gt;Insert into table TableD select var1, var2, var2&lt;/P&gt;&lt;P&gt;"&amp;nbsp;--...&lt;/P&gt;</description>
    <pubDate>Mon, 16 Sep 2019 21:07:32 GMT</pubDate>
    <dc:creator>ChineduLB</dc:creator>
    <dc:date>2019-09-16T21:07:32Z</dc:date>
    <item>
      <title>Store intermediate Query Result to variable in Beeline-Hive</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Store-intermediate-Query-Result-to-variable-in-Beeline-Hive/m-p/277389#M207546</link>
      <description>&lt;P&gt;Is there a way to store intermediate query results in&amp;nbsp;Beeline - Hive&lt;/P&gt;&lt;P&gt;something like below in pseudo code. within a beeline session&lt;/P&gt;&lt;P&gt;beeline -u&amp;nbsp; -e"&lt;/P&gt;&lt;P&gt;&amp;nbsp;set var1 = select max(date) from tableA;&lt;/P&gt;&lt;P&gt;&amp;nbsp;set var2 = select count(emps) from tableB;&lt;/P&gt;&lt;P&gt;set var3 = select min(date) from tableC;&lt;/P&gt;&lt;P&gt;Insert into table TableD select var1, var2, var2&lt;/P&gt;&lt;P&gt;"&amp;nbsp;--...&lt;/P&gt;</description>
      <pubDate>Mon, 16 Sep 2019 21:07:32 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Store-intermediate-Query-Result-to-variable-in-Beeline-Hive/m-p/277389#M207546</guid>
      <dc:creator>ChineduLB</dc:creator>
      <dc:date>2019-09-16T21:07:32Z</dc:date>
    </item>
    <item>
      <title>Re: Store intermediate Query Result to variable in Beeline-Hive</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Store-intermediate-Query-Result-to-variable-in-Beeline-Hive/m-p/277391#M207548</link>
      <description>&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/32170"&gt;@ChineduLB&lt;/a&gt;&lt;BR /&gt;&lt;BR /&gt;No you can't, you can only save data into temp tables, or simply use sub-query instead.&lt;BR /&gt;&lt;BR /&gt;Cheers&lt;BR /&gt;Eric</description>
      <pubDate>Mon, 16 Sep 2019 22:14:12 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Store-intermediate-Query-Result-to-variable-in-Beeline-Hive/m-p/277391#M207548</guid>
      <dc:creator>EricL</dc:creator>
      <dc:date>2019-09-16T22:14:12Z</dc:date>
    </item>
  </channel>
</rss>

