<?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: Saving an output dataset using Proc genmod and HADOOP/Impala in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Saving-an-output-dataset-using-Proc-genmod-and-HADOOP-Impala/m-p/304499#M60841</link>
    <description>&lt;P&gt;Did you try sending the output from genmod to a different library than the source data? I'm not sure that the model procedures' ODS OUTPUT&amp;nbsp;speaks HADOOP for output&lt;/P&gt;</description>
    <pubDate>Thu, 13 Oct 2016 22:53:21 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2016-10-13T22:53:21Z</dc:date>
    <item>
      <title>Saving an output dataset using Proc genmod and HADOOP/Impala</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-an-output-dataset-using-Proc-genmod-and-HADOOP-Impala/m-p/304491#M60839</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have a dataset that is housed in Hadoop HDFS and I would like to perform a proc genmod using this dataset. &amp;nbsp;For instance, my libname is set as&amp;nbsp;&lt;/P&gt;
&lt;P&gt;libname dchd odbc dsn='xxx' schema='data' dbcommit=99999 insertbuff=99999 readbuff=99999;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have created a dataset called 'ds' that is stored in HDFS as data.ds&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I now want to perform genmod as follows&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ods output Estimates=data.output&amp;nbsp; (keep=event cohort_year Label MeanEstimate MeanLowerCL MeanUpperCL);&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc genmod data=data.ds;&lt;/P&gt;
&lt;P&gt;model num_event= /d=p link=log offset=log_years;&lt;/P&gt;
&lt;P&gt;by event cohort_year;&lt;BR /&gt; estimate " " int 1 /exp ;&lt;BR /&gt; ods select modelinfo parameterestimates estimates modelfit;&lt;BR /&gt;run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The model runs fine but when I try to store an output dataset I get this error:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ERROR: During insert: [Simba][ImpalaODBC] (110) Error while executing a query in Impala: [HY000] : AnalysisException: Possible loss &lt;BR /&gt; of precision for target table 'aellman.OUTPUTH1'. Expression 'cast(2008 as double)' (type: DOUBLE) would need to be cast to &lt;BR /&gt; DECIMAL(11,0) for column 'cohort_year'&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am running Enterprise Guide 7.12&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;Further text from log:&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;ERROR: During insert: [Simba][ImpalaODBC] (110) Error while executing a query in Impala: [HY000] : AnalysisException: Possible loss &lt;BR /&gt; of precision for target table 'aellman.OUTPUTH1'. Expression 'cast(2008 as double)' (type: DOUBLE) would need to be cast to &lt;BR /&gt; DECIMAL(11,0) for column 'cohort_year' &lt;BR /&gt;NOTE: PROCEDURE GENMOD used (Total process time):&lt;BR /&gt; real time 7.95 seconds&lt;BR /&gt; user cpu time 2.72 seconds&lt;BR /&gt; system cpu time 0.17 seconds&lt;BR /&gt; memory 10176.15k&lt;BR /&gt; OS Memory 34488.00k&lt;BR /&gt; Timestamp 10/13/2016 02:50:50 PM&lt;BR /&gt; Step Count 75 Switch Count 1864&lt;BR /&gt; Page Faults 0&lt;BR /&gt; Page Reclaims 0&lt;BR /&gt; Page Swaps 0&lt;BR /&gt; Voluntary Context Switches 7810&lt;BR /&gt; Involuntary Context Switches 43&lt;BR /&gt; Block Input Operations 0&lt;BR /&gt; Block Output Operations 0&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 13 Oct 2016 21:53:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-an-output-dataset-using-Proc-genmod-and-HADOOP-Impala/m-p/304491#M60839</guid>
      <dc:creator>aellman</dc:creator>
      <dc:date>2016-10-13T21:53:41Z</dc:date>
    </item>
    <item>
      <title>Re: Saving an output dataset using Proc genmod and HADOOP/Impala</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-an-output-dataset-using-Proc-genmod-and-HADOOP-Impala/m-p/304499#M60841</link>
      <description>&lt;P&gt;Did you try sending the output from genmod to a different library than the source data? I'm not sure that the model procedures' ODS OUTPUT&amp;nbsp;speaks HADOOP for output&lt;/P&gt;</description>
      <pubDate>Thu, 13 Oct 2016 22:53:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-an-output-dataset-using-Proc-genmod-and-HADOOP-Impala/m-p/304499#M60841</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2016-10-13T22:53:21Z</dc:date>
    </item>
    <item>
      <title>Re: Saving an output dataset using Proc genmod and HADOOP/Impala</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-an-output-dataset-using-Proc-genmod-and-HADOOP-Impala/m-p/304505#M60842</link>
      <description>&lt;P&gt;Maybe Hadoop is different but the convention is typically libname.memname.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Youre trying to do schemaname.memname&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I would try just using the work library for starters though.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Ods output estimates=output;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Usually the ODS SELECT statement also precedes the proc, but not a requirement.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 14 Oct 2016 00:46:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-an-output-dataset-using-Proc-genmod-and-HADOOP-Impala/m-p/304505#M60842</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-10-14T00:46:01Z</dc:date>
    </item>
  </channel>
</rss>

