<?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: GOPTIONS NOACCESSIBLE appears inside variable text put in log in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418490#M102809</link>
    <description>&lt;P&gt;The problem is your use of quotes in macro variables, which is VERY BAD practice, as you just experience. It's just that additional code ends up in there, because SAS has problems finding the end of the string. This additional code is sent as "opening" and "closing" wrapper around your code by EG.&lt;/P&gt;
&lt;P&gt;Now there are ways to make this work, but it's much easier to wrap quotes around text where they are needed, not where the text is defined.&lt;/P&gt;
&lt;P&gt;EG&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%let text1 = hello ; 
%let text2 = bye ;
data _null_;
call symput('text3',"'&amp;amp;text1.&amp;amp;text2.'");
run;

%put &amp;amp;text3 ;&lt;/CODE&gt;&amp;nbsp;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 05 Dec 2017 15:00:09 GMT</pubDate>
    <dc:creator>Kurt_Bremser</dc:creator>
    <dc:date>2017-12-05T15:00:09Z</dc:date>
    <item>
      <title>GOPTIONS NOACCESSIBLE appears inside variable text put in log</title>
      <link>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418479#M102802</link>
      <description>&lt;P&gt;hello ,&lt;/P&gt;&lt;P&gt;I would like (dummy example) to get the text 'hellobye' in a macro varaible. by running this code, the result in the log is&lt;/P&gt;&lt;P&gt;'hellobye GOPTIONS NOACCESSIBLE'. how to prevent the text "GOPTIONS NOACCESSIBLE" to be inserted ?&lt;/P&gt;&lt;P&gt;Thanks a lot in adance&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;Nasser&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%let text1 = hello ; 
%let text2 = bye ;
%let text3 = %str(%')&amp;amp;text1.&amp;amp;text2.%str(%') ;
%put &amp;amp;text3 ;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Dec 2017 14:09:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418479#M102802</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2017-12-05T14:09:46Z</dc:date>
    </item>
    <item>
      <title>Re: GOPTIONS NOACCESSIBLE appears inside variable text put in log</title>
      <link>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418483#M102804</link>
      <description>&lt;P&gt;Its really not a good idea to put quotes of any kind in a macro variable, as you can tell just from the snippet you post it really makes coding and quoting so much harder and there is no reason for it.&lt;/P&gt;
&lt;PRE&gt;%let text1 = hello ; 
%let text2 = bye ;
%let text3 = &amp;amp;text1.&amp;amp;text2.;
%put "&amp;amp;text3.";&lt;/PRE&gt;</description>
      <pubDate>Tue, 05 Dec 2017 14:28:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418483#M102804</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2017-12-05T14:28:17Z</dc:date>
    </item>
    <item>
      <title>Re: GOPTIONS NOACCESSIBLE appears inside variable text put in log</title>
      <link>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418485#M102805</link>
      <description>&lt;P&gt;Macro best practices aside...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you are using SAS Enterprise Guide and you want to suppress this GOPTIONS statement, select the option from Tools-&amp;gt;Options-&amp;gt;Results, Graph panel:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="suppress.png" style="width: 303px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/17027i7E1CA265D8DCA679/image-size/large?v=v2&amp;amp;px=999" role="button" title="suppress.png" alt="suppress.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Dec 2017 14:39:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418485#M102805</guid>
      <dc:creator>ChrisHemedinger</dc:creator>
      <dc:date>2017-12-05T14:39:59Z</dc:date>
    </item>
    <item>
      <title>Re: GOPTIONS NOACCESSIBLE appears inside variable text put in log</title>
      <link>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418486#M102806</link>
      <description>&lt;P&gt;Thanks Chris,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have seleted this option but the problem remains&lt;/P&gt;</description>
      <pubDate>Tue, 05 Dec 2017 14:44:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418486#M102806</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2017-12-05T14:44:53Z</dc:date>
    </item>
    <item>
      <title>Re: GOPTIONS NOACCESSIBLE appears inside variable text put in log</title>
      <link>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418488#M102807</link>
      <description>&lt;P&gt;thanks a lot RW9, but I need the ' to specify the file (with&amp;nbsp;its folder) in ODS TAGSETS like this&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;ODS TAGSETS.EXCELXP FILE = &lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;"&amp;amp;file."&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;&lt;FONT face="Courier New" size="3"&gt;how could I obtain this &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New"&gt;ODS TAGSETS.EXCELXP FILE =&amp;nbsp;&lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;'&lt;FONT face="Courier New"&gt;data/saswork/file_name.xml&lt;/FONT&gt;'&lt;/FONT&gt; ;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;by loading the folder and the file in a macro variable ?&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;thanks&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Dec 2017 14:52:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418488#M102807</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2017-12-05T14:52:26Z</dc:date>
    </item>
    <item>
      <title>Re: GOPTIONS NOACCESSIBLE appears inside variable text put in log</title>
      <link>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418489#M102808</link>
      <description>&lt;P&gt;And where is the problem? You use double quotes when specifying the output file for ods, simple as that.&lt;/P&gt;</description>
      <pubDate>Tue, 05 Dec 2017 14:58:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418489#M102808</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2017-12-05T14:58:37Z</dc:date>
    </item>
    <item>
      <title>Re: GOPTIONS NOACCESSIBLE appears inside variable text put in log</title>
      <link>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418490#M102809</link>
      <description>&lt;P&gt;The problem is your use of quotes in macro variables, which is VERY BAD practice, as you just experience. It's just that additional code ends up in there, because SAS has problems finding the end of the string. This additional code is sent as "opening" and "closing" wrapper around your code by EG.&lt;/P&gt;
&lt;P&gt;Now there are ways to make this work, but it's much easier to wrap quotes around text where they are needed, not where the text is defined.&lt;/P&gt;
&lt;P&gt;EG&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%let text1 = hello ; 
%let text2 = bye ;
data _null_;
call symput('text3',"'&amp;amp;text1.&amp;amp;text2.'");
run;

%put &amp;amp;text3 ;&lt;/CODE&gt;&amp;nbsp;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Dec 2017 15:00:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418490#M102809</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2017-12-05T15:00:09Z</dc:date>
    </item>
    <item>
      <title>Re: GOPTIONS NOACCESSIBLE appears inside variable text put in log</title>
      <link>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418492#M102810</link>
      <description>&lt;P&gt;Your code would look like this:&lt;/P&gt;
&lt;PRE&gt;%let fname=data/saswork/file_name.xml;

ods tagsets.excelxp file="&amp;amp;fname.";&lt;/PRE&gt;
&lt;P&gt;No need for any additional quotes.&lt;/P&gt;</description>
      <pubDate>Tue, 05 Dec 2017 15:03:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418492#M102810</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2017-12-05T15:03:20Z</dc:date>
    </item>
    <item>
      <title>Re: GOPTIONS NOACCESSIBLE appears inside variable text put in log</title>
      <link>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418535#M102826</link>
      <description>&lt;P&gt;Kurt,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;by lauching your code , the result is&amp;nbsp; 'hellobye GOPTIONS NOACCESSIBLE'&lt;/P&gt;&lt;P&gt;i succeed to prevent the GOPTIONS NOACCESSIBLE only by closing and restart sas EG.&lt;/P&gt;&lt;P&gt;thanks all for your help&lt;/P&gt;</description>
      <pubDate>Tue, 05 Dec 2017 17:02:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/GOPTIONS-NOACCESSIBLE-appears-inside-variable-text-put-in-log/m-p/418535#M102826</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2017-12-05T17:02:45Z</dc:date>
    </item>
  </channel>
</rss>

