<?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 Insufficient memory in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Insufficient-memory/m-p/452306#M29185</link>
    <description>&lt;P&gt;Hello everybody,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I submitted the following code:&amp;nbsp;&lt;/P&gt;&lt;P&gt;proc sort data=WORK.FAMA3CONDITION out=date (keep=date) nodupkey;&lt;BR /&gt;by date;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;proc surveyselect data=WORK.date out=outbootdate /*we tell the input and output dataset name*/&lt;BR /&gt;seed=30459584 /*We specify a random seed*/&lt;BR /&gt;method=urs /*We specify the type of random sampling (simple random sampling with replacement here)*/&lt;BR /&gt;samprate=1 /*In order to get a sample of the same size as our original data set, equal to 1 to have 100% sample*/&lt;BR /&gt;outhits /*makes sure that it generates an output record every time it hits a given record, rather than only the first time*/&lt;BR /&gt;reps=1000; /*replicates the number of sample*/&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;data outbootdate_1;&lt;BR /&gt;set outbootdate;&lt;BR /&gt;link=00;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;data FAMA3CONDITION_1;&lt;BR /&gt;set FAMA3CONDITION;&lt;BR /&gt;link=00;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;proc sql ;&lt;BR /&gt;create table new_boot&lt;BR /&gt;as select&lt;BR /&gt;a.*,b.*&lt;BR /&gt;from outbootdate_1 as a&lt;BR /&gt;left join FAMA3CONDITION_1 as b on a.link=b.link and a.date=b.date;&lt;BR /&gt;quit;&lt;/P&gt;&lt;P&gt;proc sort data=new_boot out= new_boot_1;&lt;BR /&gt;by replicate id date;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;proc reg data=new_boot_1 outest=new_boot_2;&lt;BR /&gt;model TRUEPERF = MKT SMB HML;&lt;BR /&gt;by Replicate id;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And it delivers the following message in the log:&lt;/P&gt;&lt;P&gt;&amp;nbsp;ERROR: The SAS System stopped processing this step because of&lt;BR /&gt;insufficient memory.&lt;BR /&gt;WARNING: The data set WORK.NEW_BOOT_2 may be incomplete. When&lt;BR /&gt;this step was stopped there were 546738 observations&lt;BR /&gt;and 11 variables.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I tried to add&amp;nbsp;&lt;BR /&gt;options memsize=max;&amp;nbsp;&lt;/P&gt;&lt;P&gt;in my code but I received a warning message telling me I had to modify SAS configuration file&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I used then the code&amp;nbsp;&lt;BR /&gt;proc options option = memsize; r&lt;/P&gt;&lt;P&gt;run;&amp;nbsp;&lt;/P&gt;&lt;P&gt;to obtain the path and modify the sasv9.cfg file&lt;/P&gt;&lt;P&gt;I changed memsize from 2G to MAX and save the changes.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;These are the info in the log about the memory:&amp;nbsp;&lt;/P&gt;&lt;P&gt;Group=MEMORY&lt;BR /&gt;SORTSIZE=1073741824&amp;nbsp; &amp;nbsp; &amp;nbsp; Specifies the amount of memory that is available to the SORT procedure.&lt;BR /&gt;SUMSIZE=0&amp;nbsp; &amp;nbsp; &amp;nbsp; Specifies a limit on the amount of memory&amp;nbsp;that is available for data summarization&amp;nbsp;procedures when class variables are active.&lt;BR /&gt;MAXMEMQUERY=0&amp;nbsp; &amp;nbsp; &amp;nbsp; Specifies the maximum amount of memory that&amp;nbsp; is allocated for procedures.&lt;BR /&gt;MEMBLKSZ=16777216&amp;nbsp; &amp;nbsp; &amp;nbsp;Specifies the memory block size for Windows&amp;nbsp;memory-based libraries.&lt;/P&gt;&lt;P&gt;MEMMAXSZ=2147483648&amp;nbsp; &amp;nbsp;Specifies the maximum amount of memory to&amp;nbsp; allocate for using memory-based libraries.&lt;BR /&gt;LOADMEMSIZE=0 Specifies a suggested amount of memory that&amp;nbsp;is needed for executable programs loaded by SAS.&lt;BR /&gt;MEMSIZE=5866245120&amp;nbsp; Specifies the limit on the amount of virtual&amp;nbsp; memory that can be used during a SAS session.&lt;BR /&gt;REALMEMSIZE=0 Specifies the amount of real memory SAS can&amp;nbsp; expect to allocate.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I launched again my code but once again I obtain the same error message.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Does some have a solution for me please?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks a lot!!&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sun, 08 Apr 2018 11:52:42 GMT</pubDate>
    <dc:creator>Max05</dc:creator>
    <dc:date>2018-04-08T11:52:42Z</dc:date>
    <item>
      <title>Insufficient memory</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Insufficient-memory/m-p/452306#M29185</link>
      <description>&lt;P&gt;Hello everybody,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I submitted the following code:&amp;nbsp;&lt;/P&gt;&lt;P&gt;proc sort data=WORK.FAMA3CONDITION out=date (keep=date) nodupkey;&lt;BR /&gt;by date;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;proc surveyselect data=WORK.date out=outbootdate /*we tell the input and output dataset name*/&lt;BR /&gt;seed=30459584 /*We specify a random seed*/&lt;BR /&gt;method=urs /*We specify the type of random sampling (simple random sampling with replacement here)*/&lt;BR /&gt;samprate=1 /*In order to get a sample of the same size as our original data set, equal to 1 to have 100% sample*/&lt;BR /&gt;outhits /*makes sure that it generates an output record every time it hits a given record, rather than only the first time*/&lt;BR /&gt;reps=1000; /*replicates the number of sample*/&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;data outbootdate_1;&lt;BR /&gt;set outbootdate;&lt;BR /&gt;link=00;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;data FAMA3CONDITION_1;&lt;BR /&gt;set FAMA3CONDITION;&lt;BR /&gt;link=00;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;proc sql ;&lt;BR /&gt;create table new_boot&lt;BR /&gt;as select&lt;BR /&gt;a.*,b.*&lt;BR /&gt;from outbootdate_1 as a&lt;BR /&gt;left join FAMA3CONDITION_1 as b on a.link=b.link and a.date=b.date;&lt;BR /&gt;quit;&lt;/P&gt;&lt;P&gt;proc sort data=new_boot out= new_boot_1;&lt;BR /&gt;by replicate id date;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;proc reg data=new_boot_1 outest=new_boot_2;&lt;BR /&gt;model TRUEPERF = MKT SMB HML;&lt;BR /&gt;by Replicate id;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And it delivers the following message in the log:&lt;/P&gt;&lt;P&gt;&amp;nbsp;ERROR: The SAS System stopped processing this step because of&lt;BR /&gt;insufficient memory.&lt;BR /&gt;WARNING: The data set WORK.NEW_BOOT_2 may be incomplete. When&lt;BR /&gt;this step was stopped there were 546738 observations&lt;BR /&gt;and 11 variables.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I tried to add&amp;nbsp;&lt;BR /&gt;options memsize=max;&amp;nbsp;&lt;/P&gt;&lt;P&gt;in my code but I received a warning message telling me I had to modify SAS configuration file&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I used then the code&amp;nbsp;&lt;BR /&gt;proc options option = memsize; r&lt;/P&gt;&lt;P&gt;run;&amp;nbsp;&lt;/P&gt;&lt;P&gt;to obtain the path and modify the sasv9.cfg file&lt;/P&gt;&lt;P&gt;I changed memsize from 2G to MAX and save the changes.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;These are the info in the log about the memory:&amp;nbsp;&lt;/P&gt;&lt;P&gt;Group=MEMORY&lt;BR /&gt;SORTSIZE=1073741824&amp;nbsp; &amp;nbsp; &amp;nbsp; Specifies the amount of memory that is available to the SORT procedure.&lt;BR /&gt;SUMSIZE=0&amp;nbsp; &amp;nbsp; &amp;nbsp; Specifies a limit on the amount of memory&amp;nbsp;that is available for data summarization&amp;nbsp;procedures when class variables are active.&lt;BR /&gt;MAXMEMQUERY=0&amp;nbsp; &amp;nbsp; &amp;nbsp; Specifies the maximum amount of memory that&amp;nbsp; is allocated for procedures.&lt;BR /&gt;MEMBLKSZ=16777216&amp;nbsp; &amp;nbsp; &amp;nbsp;Specifies the memory block size for Windows&amp;nbsp;memory-based libraries.&lt;/P&gt;&lt;P&gt;MEMMAXSZ=2147483648&amp;nbsp; &amp;nbsp;Specifies the maximum amount of memory to&amp;nbsp; allocate for using memory-based libraries.&lt;BR /&gt;LOADMEMSIZE=0 Specifies a suggested amount of memory that&amp;nbsp;is needed for executable programs loaded by SAS.&lt;BR /&gt;MEMSIZE=5866245120&amp;nbsp; Specifies the limit on the amount of virtual&amp;nbsp; memory that can be used during a SAS session.&lt;BR /&gt;REALMEMSIZE=0 Specifies the amount of real memory SAS can&amp;nbsp; expect to allocate.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I launched again my code but once again I obtain the same error message.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Does some have a solution for me please?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks a lot!!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 08 Apr 2018 11:52:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Insufficient-memory/m-p/452306#M29185</guid>
      <dc:creator>Max05</dc:creator>
      <dc:date>2018-04-08T11:52:42Z</dc:date>
    </item>
    <item>
      <title>Re: Insufficient memory</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Insufficient-memory/m-p/452313#M29186</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/201052"&gt;@Max05&lt;/a&gt;&lt;/P&gt;
&lt;P&gt;The SAS log indicates that the memory issues occur within your last step (&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;proc&lt;/STRONG&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;reg&lt;/FONT&gt;&lt;/STRONG&gt;&amp;nbsp;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT color="#0000ff"&gt;...&lt;/FONT&gt; &lt;FONT color="#0000ff"&gt;outest&lt;/FONT&gt;=new_boot_2 )&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;That's the step you need to look into.&lt;/P&gt;
&lt;P&gt;I don't have the expertise to give you advice on&amp;nbsp;how to formulate less memory intensive code for Proc Reg but if you're executing this out of SAS EG then it's may be worth looking into the following: &lt;A href="http://support.sas.com/kb/40/480.html" target="_blank"&gt;http://support.sas.com/kb/40/480.html&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 08 Apr 2018 13:06:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Insufficient-memory/m-p/452313#M29186</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2018-04-08T13:06:22Z</dc:date>
    </item>
  </channel>
</rss>

