<?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 How  can I export to a file path that contains an apostrophe? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-can-I-export-to-a-file-path-that-contains-an-apostrophe/m-p/915952#M360846</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to export to a file that contains an apostrophe using the following:&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=""&gt;proc export data=datasas2
outfile="C:\user\filepath\John's Folder\file.xlsx"
dbms=excel replace;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;I've tried to place the file path in a macro using %let with %quote, but I'm sure that I'm not using this correctly.&lt;/P&gt;&lt;P&gt;Please help.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Many thanks,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;JFuchsia&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 13 Feb 2024 23:01:17 GMT</pubDate>
    <dc:creator>JFuchsia</dc:creator>
    <dc:date>2024-02-13T23:01:17Z</dc:date>
    <item>
      <title>How  can I export to a file path that contains an apostrophe?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-can-I-export-to-a-file-path-that-contains-an-apostrophe/m-p/915952#M360846</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to export to a file that contains an apostrophe using the following:&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=""&gt;proc export data=datasas2
outfile="C:\user\filepath\John's Folder\file.xlsx"
dbms=excel replace;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;I've tried to place the file path in a macro using %let with %quote, but I'm sure that I'm not using this correctly.&lt;/P&gt;&lt;P&gt;Please help.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Many thanks,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;JFuchsia&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 13 Feb 2024 23:01:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-can-I-export-to-a-file-path-that-contains-an-apostrophe/m-p/915952#M360846</guid>
      <dc:creator>JFuchsia</dc:creator>
      <dc:date>2024-02-13T23:01:17Z</dc:date>
    </item>
    <item>
      <title>Re: How  can I export to a file path that contains an apostrophe?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-can-I-export-to-a-file-path-that-contains-an-apostrophe/m-p/915953#M360847</link>
      <description>PS. I can't change the file path due to some pretty strict IT constraints. Thanks.</description>
      <pubDate>Tue, 13 Feb 2024 23:02:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-can-I-export-to-a-file-path-that-contains-an-apostrophe/m-p/915953#M360847</guid>
      <dc:creator>JFuchsia</dc:creator>
      <dc:date>2024-02-13T23:02:57Z</dc:date>
    </item>
    <item>
      <title>Re: How  can I export to a file path that contains an apostrophe?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-can-I-export-to-a-file-path-that-contains-an-apostrophe/m-p/915958#M360850</link>
      <description>&lt;P&gt;The code you showed should work fine.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So what code did you try that did NOT work?&lt;/P&gt;</description>
      <pubDate>Tue, 13 Feb 2024 23:45:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-can-I-export-to-a-file-path-that-contains-an-apostrophe/m-p/915958#M360850</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2024-02-13T23:45:59Z</dc:date>
    </item>
    <item>
      <title>Re: How  can I export to a file path that contains an apostrophe?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-can-I-export-to-a-file-path-that-contains-an-apostrophe/m-p/915960#M360852</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/463731"&gt;@JFuchsia&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;PS. I can't change the file path due to some pretty strict IT constraints. Thanks.&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;"Strict IT constraints" and apostrophe in path points to a pretty not-tech savvy IT.&amp;nbsp; Spaces in file paths are enough of a challenge (looking at the path might not tell the difference between one or two spaces easily) but special characters like comma * dash single quote or double quote are just asking for all sorts of stupid problems.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;One stupid problem involving quotes is the ASCII ' or " character versus "smart quotes" which have a curly appearance and often not noticed by folks. If your actual path uses the curly quotes you don't have the correct character on your keyboard.&lt;/P&gt;</description>
      <pubDate>Wed, 14 Feb 2024 00:03:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-can-I-export-to-a-file-path-that-contains-an-apostrophe/m-p/915960#M360852</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2024-02-14T00:03:11Z</dc:date>
    </item>
    <item>
      <title>Re: How  can I export to a file path that contains an apostrophe?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-can-I-export-to-a-file-path-that-contains-an-apostrophe/m-p/915978#M360866</link>
      <description>&lt;P&gt;Just put the whole path you used in the example code into the macro variable.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;There is no need for macro quoting when you have real quoting.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%let filename="C:\user\filepath\John's Folder\file.xlsx";
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Then just use the macro variable where you need a quoted filename.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc export data=datasas2
  outfile=&amp;amp;filename
  dbms=xlsx replace
;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 14 Feb 2024 02:06:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-can-I-export-to-a-file-path-that-contains-an-apostrophe/m-p/915978#M360866</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2024-02-14T02:06:24Z</dc:date>
    </item>
    <item>
      <title>Re: How  can I export to a file path that contains an apostrophe?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-can-I-export-to-a-file-path-that-contains-an-apostrophe/m-p/916050#M360896</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13884"&gt;@ballardw&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/463731"&gt;@JFuchsia&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;PS. I can't change the file path due to some pretty strict IT constraints. Thanks.&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;"Strict IT constraints" and apostrophe in path points to a pretty not-tech savvy IT.&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Nicely said. I would have called them "brain-amputated idiots".&lt;/P&gt;</description>
      <pubDate>Wed, 14 Feb 2024 13:29:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-can-I-export-to-a-file-path-that-contains-an-apostrophe/m-p/916050#M360896</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2024-02-14T13:29:14Z</dc:date>
    </item>
  </channel>
</rss>

