<?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: SAS MACRO NOT RUNNING in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/715065#M220838</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/159"&gt;@Tom&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;It is waiting for you to submit the right parentheses for all of these unbalanced pairs.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%kw_edu( (se_cr)  /* Missing ) */
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;To get you session back submit:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;*))))))))))))))))))))))))))))))))))))))))))))))));&lt;/CODE&gt;&lt;/PRE&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;But how many times id the OP submit the same code hoping it will run "this time"? Or just one or two of the macro calls? Possibly including attempts to redefine the macro? Likely going to be lots of fun guessing how many ) are really needed.&lt;/P&gt;</description>
    <pubDate>Thu, 28 Jan 2021 17:14:09 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2021-01-28T17:14:09Z</dc:date>
    <item>
      <title>SAS MACRO NOT RUNNING</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/714849#M220746</link>
      <description>&lt;P&gt;Hi, my macro will stop when running to a certain line. The log is as below: %kw_edu(se) runs well but %kw_edu(se_cr) stop running suddenly. Why did it happen?&lt;/P&gt;&lt;PRE&gt;244
245  %macro kw_edu(x);
246  proc npar1way data = shs.hsb2 wilcoxon;
247  class s1edu_cat;
248  format s1edu_cat education.;
249  var &amp;amp;x;
250  run;
251  %mend;
252
253  %kw_edu(se)
NOTE: Data file SHS.HSB2.DATA is in a format that is native to another host, or the file encoding
      does not match the session encoding. Cross Environment Data Access will be used, which might
      require additional CPU resources and might reduce performance.

NOTE: PROCEDURE NPAR1WAY used (Total process time):
      real time           0.87 seconds
      cpu time            0.50 seconds


254  %kw_edu((se_cr)
255  %kw_edu((zn)
256  %kw_edu((zn_cr)
257  %kw_edu((sb)
258  %kw_edu((sb_cr)
259  %kw_edu((cd)
260  %kw_edu((cd_cr)
261  %kw_edu((pb)
262  %kw_edu((pb_cr)&lt;/PRE&gt;</description>
      <pubDate>Thu, 28 Jan 2021 00:28:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/714849#M220746</guid>
      <dc:creator>gx2144</dc:creator>
      <dc:date>2021-01-28T00:28:05Z</dc:date>
    </item>
    <item>
      <title>Re: SAS MACRO NOT RUNNING</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/714852#M220749</link>
      <description>Add the option before your macros:&lt;BR /&gt;&lt;BR /&gt;options mprint mlogic;&lt;BR /&gt;&lt;BR /&gt;Re-run your macros and then post the log.</description>
      <pubDate>Thu, 28 Jan 2021 00:41:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/714852#M220749</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2021-01-28T00:41:22Z</dc:date>
    </item>
    <item>
      <title>Re: SAS MACRO NOT RUNNING</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/714859#M220753</link>
      <description>&lt;PRE&gt;253  %kw_edu(se)
MLOGIC(KW_EDU):  Beginning execution.
MLOGIC(KW_EDU):  Parameter X has value se
NOTE: Data file SHS.HSB2.DATA is in a format that is native to another host, or the file encoding
      does not match the session encoding. Cross Environment Data Access will be used, which might
      require additional CPU resources and might reduce performance.
MPRINT(KW_EDU):   proc npar1way data = shs.hsb2 wilcoxon;
MPRINT(KW_EDU):   class s1edu_cat;
MPRINT(KW_EDU):   format s1edu_cat education.;
MPRINT(KW_EDU):   var se;
MPRINT(KW_EDU):   run;

NOTE: PROCEDURE NPAR1WAY used (Total process time):
      real time           0.49 seconds
      cpu time            0.37 seconds


MLOGIC(KW_EDU):  Ending execution.
254  %kw_edu((se_cr)
MLOGIC(KW_EDU):  Beginning execution.
255  %kw_edu((zn)
MLOGIC(KW_EDU):  Beginning execution.
256  %kw_edu((zn_cr)
MLOGIC(KW_EDU):  Beginning execution.
257  %kw_edu((sb)
MLOGIC(KW_EDU):  Beginning execution.
258  %kw_edu((sb_cr)
MLOGIC(KW_EDU):  Beginning execution.
259  %kw_edu((cd)
MLOGIC(KW_EDU):  Beginning execution.
260  %kw_edu((cd_cr)
MLOGIC(KW_EDU):  Beginning execution.
261  %kw_edu((pb)
MLOGIC(KW_EDU):  Beginning execution.
262  %kw_edu((pb_cr)
MLOGIC(KW_EDU):  Beginning execution.
263  %kw_edu((mo)
MLOGIC(KW_EDU):  Beginning execution.
264  %kw_edu((mo_cr)
MLOGIC(KW_EDU):  Beginning execution.
265  %kw_edu((w)
MLOGIC(KW_EDU):  Beginning execution.
266  %kw_edu((w_cr)
MLOGIC(KW_EDU):  Beginning execution.
267  %kw_edu((u)
MLOGIC(KW_EDU):  Beginning execution.
268  %kw_edu((u_cr)
MLOGIC(KW_EDU):  Beginning execution.
269  %kw_edu((sum_all)
MLOGIC(KW_EDU):  Beginning execution.
270  %kw_edu((sum_all_cr);
MLOGIC(KW_EDU):  Beginning execution.
271
272  /*smoking status*/
273  proc sort data = shs.hsb2;
274  by s1smoke_n;
275  run;
276
277  proc univariate data = shs.hsb2 noprint ;
278  histogram se se_cr zn zn_cr sb sb_cr cd cd_cr pb pb_cr mo mo_cr w w_cr u u_cr/NORMAL;
279  qqplot/normal;
280  run;
281
282  proc means data = shs.hsb2  N Mean Median  P25 P75 MaxDec = 3;
283  var se se_cr zn zn_cr sb sb_cr sum_all sum_all_cr cd cd_cr pb pb_cr mo mo_cr w w_cr u u_cr;
284  class s1smoke_n;
285  format s1smoke_n drink_smoke.;
286  run;
287
288  %macro kw_smoke(x);
289  proc npar1way data = shs.hsb2 wilcoxon;
290  class s1smoke_n;
291  format s1smoke_n drink_smoke.;
292  var &amp;amp;x;
293  run;
294  %mend;
295
296  %kw_smoke(se)
MLOGIC(KW_SMOKE):  Beginning execution.
MLOGIC(KW_SMOKE):  Parameter X has value se
MLOGIC(KW_SMOKE):  Ending execution.
297  %kw_smoke((se_cr);
MLOGIC(KW_SMOKE):  Beginning execution.
298  %kw_smoke((zn)
MLOGIC(KW_SMOKE):  Beginning execution.
299  %kw_smoke((zn_cr)
MLOGIC(KW_SMOKE):  Beginning execution.
300  %kw_smoke((sb)
MLOGIC(KW_SMOKE):  Beginning execution.
301  %kw_smoke((sb_cr)
MLOGIC(KW_SMOKE):  Beginning execution.
302  %kw_smoke((cd)
MLOGIC(KW_SMOKE):  Beginning execution.
303  %kw_smoke((cd_cr)
MLOGIC(KW_SMOKE):  Beginning execution.
304  %kw_smoke((pb)
MLOGIC(KW_SMOKE):  Beginning execution.
305  %kw_smoke((pb_cr)
MLOGIC(KW_SMOKE):  Beginning execution.
306  %kw_smoke((mo)
MLOGIC(KW_SMOKE):  Beginning execution.
307  %kw_smoke((mo_cr)
MLOGIC(KW_SMOKE):  Beginning execution.
308  %kw_smoke((w)
MLOGIC(KW_SMOKE):  Beginning execution.
309  %kw_smoke((w_cr)
MLOGIC(KW_SMOKE):  Beginning execution.
310  %kw_smoke((u)
MLOGIC(KW_SMOKE):  Beginning execution.
311  %kw_smoke((u_cr)
MLOGIC(KW_SMOKE):  Beginning execution.
312  %kw_smoke((sum_all)
MLOGIC(KW_SMOKE):  Beginning execution.
313  %kw_smoke((sum_all_cr)
MLOGIC(KW_SMOKE):  Beginning execution.&lt;/PRE&gt;&lt;P&gt;It stops running after the first line of %kw_edu(se)&lt;/P&gt;</description>
      <pubDate>Thu, 28 Jan 2021 01:53:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/714859#M220753</guid>
      <dc:creator>gx2144</dc:creator>
      <dc:date>2021-01-28T01:53:53Z</dc:date>
    </item>
    <item>
      <title>Re: SAS MACRO NOT RUNNING</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/714878#M220758</link>
      <description>&lt;P&gt;It seems to me that you miss semicolons and you doubled the open parenthesis.&lt;/P&gt;
&lt;P&gt;Should not code be:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%kw_edu(se);
%kw_edu(se_cr);
%kw_edu(zn);
%kw_edu(zn_cr);
%kw_edu(sb);
%kw_edu(sb_cr);
%kw_edu(cd);
%kw_edu(cd_cr);
%kw_edu(pb);
%kw_edu(pb_cr);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 28 Jan 2021 05:49:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/714878#M220758</guid>
      <dc:creator>Shmuel</dc:creator>
      <dc:date>2021-01-28T05:49:00Z</dc:date>
    </item>
    <item>
      <title>Betreff: SAS MACRO NOT RUNNING</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/714879#M220759</link>
      <description>Your brackets are not balanced. Try %kw_edu(se_cr) instead auf %kw_edu((se_cr).</description>
      <pubDate>Thu, 28 Jan 2021 05:50:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/714879#M220759</guid>
      <dc:creator>KlausBücher</dc:creator>
      <dc:date>2021-01-28T05:50:23Z</dc:date>
    </item>
    <item>
      <title>Re: SAS MACRO NOT RUNNING</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/715031#M220825</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/334360"&gt;@gx2144&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hi, my macro will stop when running to a certain line. The log is as below: %kw_edu(se) runs well but %kw_edu(se_cr) stop running suddenly. Why did it happen?&lt;/P&gt;
&lt;PRE&gt;244
245  %macro kw_edu(x);
246  proc npar1way data = shs.hsb2 wilcoxon;
247  class s1edu_cat;
248  format s1edu_cat education.;
249  var &amp;amp;x;
250  run;
251  %mend;
252
253  %kw_edu(se)
NOTE: Data file SHS.HSB2.DATA is in a format that is native to another host, or the file encoding
      does not match the session encoding. Cross Environment Data Access will be used, which might
      require additional CPU resources and might reduce performance.

NOTE: PROCEDURE NPAR1WAY used (Total process time):
      real time           0.87 seconds
      cpu time            0.50 seconds


254  %kw_edu((se_cr)
255  %kw_edu((zn)
256  %kw_edu((zn_cr)
257  %kw_edu((sb)
258  %kw_edu((sb_cr)
259  %kw_edu((cd)
260  %kw_edu((cd_cr)
261  %kw_edu((pb)
262  %kw_edu((pb_cr)&lt;/PRE&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;All of these:&lt;/P&gt;
&lt;PRE&gt;254  %kw_edu(&lt;FONT color="#FF0000"&gt;(&lt;/FONT&gt;se_cr)
255  %kw_edu(&lt;FONT color="#FF0000"&gt;(&lt;/FONT&gt;zn)
256  %kw_edu(&lt;FONT color="#FF0000"&gt;(&lt;/FONT&gt;zn_cr)
257  %kw_edu((sb)
258  %kw_edu((sb_cr)
259  %kw_edu((cd)
260  %kw_edu((cd_cr)
261  %kw_edu((pb)
262  %kw_edu((pb_cr)&lt;/PRE&gt;
&lt;P&gt;Starting at line 254 the (( means that the FOLLOWING line is considered as part of the preceding macro call and stacking up lots of unbalanced (.&lt;/P&gt;
&lt;P&gt;So the SAS system is likely unstable and needs to be shut down and restarted to clean the macro stack. Then BEFORE executing that code, replace the (( with single (.&lt;/P&gt;</description>
      <pubDate>Thu, 28 Jan 2021 15:38:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/715031#M220825</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2021-01-28T15:38:20Z</dc:date>
    </item>
    <item>
      <title>Re: SAS MACRO NOT RUNNING</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/715053#M220832</link>
      <description>&lt;P&gt;It is waiting for you to submit the right parentheses for all of these unbalanced pairs.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%kw_edu( (se_cr)  /* Missing ) */
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;To get you session back submit:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;*))))))))))))))))))))))))))))))))))))))))))))))));&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 28 Jan 2021 16:37:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/715053#M220832</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2021-01-28T16:37:45Z</dc:date>
    </item>
    <item>
      <title>Re: SAS MACRO NOT RUNNING</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/715065#M220838</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/159"&gt;@Tom&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;It is waiting for you to submit the right parentheses for all of these unbalanced pairs.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%kw_edu( (se_cr)  /* Missing ) */
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;To get you session back submit:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;*))))))))))))))))))))))))))))))))))))))))))))))));&lt;/CODE&gt;&lt;/PRE&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;But how many times id the OP submit the same code hoping it will run "this time"? Or just one or two of the macro calls? Possibly including attempts to redefine the macro? Likely going to be lots of fun guessing how many ) are really needed.&lt;/P&gt;</description>
      <pubDate>Thu, 28 Jan 2021 17:14:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-MACRO-NOT-RUNNING/m-p/715065#M220838</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2021-01-28T17:14:09Z</dc:date>
    </item>
  </channel>
</rss>

