<?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: Write sas table to hiveon hadoop in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Write-sas-table-to-hiveon-hadoop/m-p/313972#M61521</link>
    <description>&lt;P&gt;John,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;it doesn't look like your procedure is complete in your example. See this techniques in processing in Hadoop paper, it has a few examples using proc sql;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://support.sas.com/resources/papers/proceedings14/SAS033-2014.pdf&amp;nbsp;" target="_blank"&gt;https://support.sas.com/resources/papers/proceedings14/SAS033-2014.pdf&amp;nbsp;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It has this sample code to write to hadoop using proc sql that might help;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc sql; connect to hadoop (server=duped user=myUserID);&lt;/P&gt;
&lt;P&gt;execute (create table myUserID_store_cnt row format delimited fields terminated by '\001' stored as textfile as select customer_rk, count(*) as total_orders from order_fact group by customer_rk) by hadoop;&lt;/P&gt;
&lt;P&gt;disconnect from hadoop;&lt;/P&gt;
&lt;P&gt;quit;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 24 Nov 2016 06:11:57 GMT</pubDate>
    <dc:creator>brusso</dc:creator>
    <dc:date>2016-11-24T06:11:57Z</dc:date>
    <item>
      <title>Write sas table to hiveon hadoop</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Write-sas-table-to-hiveon-hadoop/m-p/313611#M61500</link>
      <description>&lt;P&gt;I would like to write a table in sas to hadoop. How do I write. My current code...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;proc sql;&lt;BR /&gt;connect to hadoop (user=john password=xxxxx server="myhadoopmachine.public.com" port=10000 SCHEMA=hiveSchema subprotocol=hive2 dbmax_text=300 CFG="/opt/sas/myhadoopmachine/myhadoopmachine_core_hdfs_site.xml");&lt;BR /&gt;execute ( create table hivelib.mytable as&lt;BR /&gt;select *&lt;BR /&gt;from saslib.mytable&lt;BR /&gt;) by hadoop ;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;results in error:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ERROR: Execute error: Error while compiling statement: FAILED: SemanticException [Error 10001]: Line 1:49 Table not found 'mytable'&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The basic issue is that I can execute sql command on hive. The above expects the saslib.mytable to be on hadoop server under the schema saslib.mytable. &amp;nbsp;saslib.mytable is my sas lib with table name mylib.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How do I pass this information in the above proc sql to copy the sas data set to hadoop.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;John&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 22 Nov 2016 22:10:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Write-sas-table-to-hiveon-hadoop/m-p/313611#M61500</guid>
      <dc:creator>johny</dc:creator>
      <dc:date>2016-11-22T22:10:07Z</dc:date>
    </item>
    <item>
      <title>Re: Write sas table to hiveon hadoop</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Write-sas-table-to-hiveon-hadoop/m-p/313972#M61521</link>
      <description>&lt;P&gt;John,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;it doesn't look like your procedure is complete in your example. See this techniques in processing in Hadoop paper, it has a few examples using proc sql;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://support.sas.com/resources/papers/proceedings14/SAS033-2014.pdf&amp;nbsp;" target="_blank"&gt;https://support.sas.com/resources/papers/proceedings14/SAS033-2014.pdf&amp;nbsp;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It has this sample code to write to hadoop using proc sql that might help;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc sql; connect to hadoop (server=duped user=myUserID);&lt;/P&gt;
&lt;P&gt;execute (create table myUserID_store_cnt row format delimited fields terminated by '\001' stored as textfile as select customer_rk, count(*) as total_orders from order_fact group by customer_rk) by hadoop;&lt;/P&gt;
&lt;P&gt;disconnect from hadoop;&lt;/P&gt;
&lt;P&gt;quit;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Nov 2016 06:11:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Write-sas-table-to-hiveon-hadoop/m-p/313972#M61521</guid>
      <dc:creator>brusso</dc:creator>
      <dc:date>2016-11-24T06:11:57Z</dc:date>
    </item>
    <item>
      <title>Re: Write sas table to hiveon hadoop</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Write-sas-table-to-hiveon-hadoop/m-p/313982#M61524</link>
      <description>If your source data resides in SAS (outside hadoop) you can't use explicit pass through, Hive is not aware of SAS data. &lt;BR /&gt;For most situations a simple create table on a Hive Libref is sufficient.</description>
      <pubDate>Thu, 24 Nov 2016 07:15:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Write-sas-table-to-hiveon-hadoop/m-p/313982#M61524</guid>
      <dc:creator>LinusH</dc:creator>
      <dc:date>2016-11-24T07:15:44Z</dc:date>
    </item>
  </channel>
</rss>

