<?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: macro quoting issue in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/macro-quoting-issue/m-p/416513#M102262</link>
    <description>&lt;P&gt;You are missing a %MEND statement for your macro:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;*%mend run_partition;&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Mon, 27 Nov 2017 21:57:09 GMT</pubDate>
    <dc:creator>SASKiwi</dc:creator>
    <dc:date>2017-11-27T21:57:09Z</dc:date>
    <item>
      <title>macro quoting issue</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-quoting-issue/m-p/416512#M102261</link>
      <description>&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Hello,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;I think I have forgotten something basic. I am trying to loop through my macro code to create ten datasets. Below is my code. When I run it as is it runs fine but when I uncomment to run the macro code block then I get the missing quote error. &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;I am not sure how quotes work but I think SAS is adding a double quote somewhere and causing this macro to not work. &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Any help appreciated. I have been manually running this 10 times )-:&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Thanks!&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;libname&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; data &lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;"H:\sasdata\eligibility"&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;options&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;symbolgen&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;mlogic&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;serror&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;merror&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;mprint&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;; &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;*%macro run_partition;&lt;/P&gt;&lt;P&gt;*%do ct=2 %to 4;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%let&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ct = 5;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%let&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; st = &amp;amp;ct.000000000;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%let&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; et = &amp;amp;ct.999999999;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%put&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; &amp;amp;st.;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%put&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; &amp;amp;et.;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;%&lt;STRONG&gt;&lt;I&gt;_eg_conditional_dropds&lt;/I&gt;&lt;/STRONG&gt;(DATA.T0265_AG_IN_ELIG_P&amp;amp;ct);&lt;/P&gt;&lt;P&gt;&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;SQL&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;CREATE&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;TABLE&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; DATA.T0265_AG_IN_ELIG_P&amp;amp;ct &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AS&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;SELECT&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;CASE_NUM&lt;/P&gt;&lt;P&gt;,PIN_NUM&lt;/P&gt;&lt;P&gt;,ELIG_RSLT_CD&lt;/P&gt;&lt;P&gt;,ELIGIBILITY_BEG_DT&lt;/P&gt;&lt;P&gt;,ELIGIBILITY_END_DT&lt;/P&gt;&lt;P&gt;,PAYMENT_BEGIN_DT&lt;/P&gt;&lt;P&gt;,PAYMENT_END_DT&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;FROM&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; CKDB.T0265_AG_IN_ELIG &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;WHERE&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; PIN_NUM &amp;gt; &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AND&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; PIN_NUM &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;between&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; &amp;amp;st &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;and&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; &amp;amp;et&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AND&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; CURRENT_ELIG_IND &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;IN&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;'1'&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;'9'&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AND&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; PROGRAM_CD = &lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;'CC'&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AND&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; SUBPROGRAM_CD &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;NOT&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;IN&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;'X'&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;'Z'&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AND&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; AG_SEQ_NUM &amp;gt; &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AND&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; CAG_ELIG_SEQ_NUM &amp;gt; &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AND&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; AG_STS_CD = &lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;'O'&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AND&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; PAYMENT_BEGIN_DT &amp;lt;= &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;'27nov2017'd&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AND&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; PAYMENT_END_DT &amp;gt;= &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;'27nov2017'd&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AND&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; PAYMENT_BEGIN_DT &amp;lt;= PAYMENT_END_DT &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AND&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; PART_STS_CD = &lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;'EA'&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;; &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;quit&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;*%end;&lt;/P&gt;&lt;P&gt;*%macro run_partition;&lt;/P&gt;&lt;P&gt;*%run_partition&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 27 Nov 2017 21:47:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-quoting-issue/m-p/416512#M102261</guid>
      <dc:creator>karnum</dc:creator>
      <dc:date>2017-11-27T21:47:11Z</dc:date>
    </item>
    <item>
      <title>Re: macro quoting issue</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-quoting-issue/m-p/416513#M102262</link>
      <description>&lt;P&gt;You are missing a %MEND statement for your macro:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;*%mend run_partition;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 27 Nov 2017 21:57:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-quoting-issue/m-p/416513#M102262</guid>
      <dc:creator>SASKiwi</dc:creator>
      <dc:date>2017-11-27T21:57:09Z</dc:date>
    </item>
    <item>
      <title>Re: macro quoting issue</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-quoting-issue/m-p/416520#M102265</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am wondering now why it is not looping through 0 through 9 when I open up this macro statement:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;%do ct=0 %to 9;&lt;/P&gt;</description>
      <pubDate>Mon, 27 Nov 2017 22:23:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-quoting-issue/m-p/416520#M102265</guid>
      <dc:creator>karnum</dc:creator>
      <dc:date>2017-11-27T22:23:35Z</dc:date>
    </item>
    <item>
      <title>Re: macro quoting issue</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-quoting-issue/m-p/416528#M102267</link>
      <description>&lt;P&gt;Comment or remove this statement:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%let ct = 5;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 27 Nov 2017 22:48:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-quoting-issue/m-p/416528#M102267</guid>
      <dc:creator>SASKiwi</dc:creator>
      <dc:date>2017-11-27T22:48:02Z</dc:date>
    </item>
  </channel>
</rss>

