<?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 creating a folder on local drive in Developers</title>
    <link>https://communities.sas.com/t5/Developers/creating-a-folder-on-local-drive/m-p/9299#M2232</link>
    <description>FILENAME mkdir pipe "mkdir d:\newfolder";&lt;BR /&gt;
data _null_;&lt;BR /&gt;
 input mkdir;&lt;BR /&gt;
 put _infile_;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
LOG:&lt;BR /&gt;
&lt;BR /&gt;
56719  FILENAME mkdir pipe "mkdir d:\newfolder";&lt;BR /&gt;
ERROR: Insufficient authorization to access PIPE.&lt;BR /&gt;
ERROR: Error in the FILENAME statement.&lt;BR /&gt;
56720  data _null_;&lt;BR /&gt;
56721   input mkdir;&lt;BR /&gt;
56722   put _infile_;&lt;BR /&gt;
56723  run;&lt;BR /&gt;
&lt;BR /&gt;
ERROR: No DATALINES or INFILE statement.&lt;BR /&gt;
ERROR: The _INFILE_ variable has been referenced, but no DATALINES or INFILE statement was found.&lt;BR /&gt;
NOTE: The SAS System stopped processing this step because of errors.&lt;BR /&gt;
NOTE: DATA statement used (Total process time):&lt;BR /&gt;
      real time           0.00 seconds&lt;BR /&gt;
      cpu time            0.00 seconds

Message was edited by: Filipvdr</description>
    <pubDate>Wed, 08 Jun 2011 09:58:06 GMT</pubDate>
    <dc:creator>Filipvdr</dc:creator>
    <dc:date>2011-06-08T09:58:06Z</dc:date>
    <item>
      <title>creating a folder on local drive</title>
      <link>https://communities.sas.com/t5/Developers/creating-a-folder-on-local-drive/m-p/9299#M2232</link>
      <description>FILENAME mkdir pipe "mkdir d:\newfolder";&lt;BR /&gt;
data _null_;&lt;BR /&gt;
 input mkdir;&lt;BR /&gt;
 put _infile_;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
LOG:&lt;BR /&gt;
&lt;BR /&gt;
56719  FILENAME mkdir pipe "mkdir d:\newfolder";&lt;BR /&gt;
ERROR: Insufficient authorization to access PIPE.&lt;BR /&gt;
ERROR: Error in the FILENAME statement.&lt;BR /&gt;
56720  data _null_;&lt;BR /&gt;
56721   input mkdir;&lt;BR /&gt;
56722   put _infile_;&lt;BR /&gt;
56723  run;&lt;BR /&gt;
&lt;BR /&gt;
ERROR: No DATALINES or INFILE statement.&lt;BR /&gt;
ERROR: The _INFILE_ variable has been referenced, but no DATALINES or INFILE statement was found.&lt;BR /&gt;
NOTE: The SAS System stopped processing this step because of errors.&lt;BR /&gt;
NOTE: DATA statement used (Total process time):&lt;BR /&gt;
      real time           0.00 seconds&lt;BR /&gt;
      cpu time            0.00 seconds

Message was edited by: Filipvdr</description>
      <pubDate>Wed, 08 Jun 2011 09:58:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/creating-a-folder-on-local-drive/m-p/9299#M2232</guid>
      <dc:creator>Filipvdr</dc:creator>
      <dc:date>2011-06-08T09:58:06Z</dc:date>
    </item>
    <item>
      <title>Re: creating a folder on local drive</title>
      <link>https://communities.sas.com/t5/Developers/creating-a-folder-on-local-drive/m-p/9300#M2233</link>
      <description>Hi:&lt;BR /&gt;
  You may need to talk to your System Administrator:&lt;BR /&gt;
[pre]&lt;BR /&gt;
ERROR: Insufficient authorization to access PIPE.&lt;BR /&gt;
[/pre]&lt;BR /&gt;
  &lt;BR /&gt;
Also, where, exactly are you trying to create the directory and are you doing this in the context of a stored process. For example, if your SP is running on a SAS  server on a Unix box, there's probably not a &lt;span class="lia-unicode-emoji" title=":anguished_face:"&gt;😧&lt;/span&gt; drive on that server. You may need to have the PIPE capability turned on and/or change your path.&lt;BR /&gt;
 &lt;BR /&gt;
  You might consider working with Tech Support on this issue.&lt;BR /&gt;
 &lt;BR /&gt;
cynthia</description>
      <pubDate>Wed, 08 Jun 2011 14:55:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/creating-a-folder-on-local-drive/m-p/9300#M2233</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2011-06-08T14:55:31Z</dc:date>
    </item>
    <item>
      <title>Re: creating a folder on local drive</title>
      <link>https://communities.sas.com/t5/Developers/creating-a-folder-on-local-drive/m-p/9301#M2234</link>
      <description>Hi Filipvdr,&lt;BR /&gt;
&lt;BR /&gt;
In addition to Cynthia's points, if you are running your stored process code in a SAS Stored Process Server or SAS Workspace Server then it is likely that pipes and executing operating system commands have been disabled via the NOXCMD option (it is the default for the SASApp application server).  If that is the case then the SAS platform administrator could possibly enable the XCMD option but it has security implications and may not be appropriate.&lt;BR /&gt;
&lt;BR /&gt;
Another way of creating directories without using pipes or operating system commands is to use the DCREATE function.  This is an SCL function but is also available in the data step.  Here is an example of creating the &lt;I&gt;newfolder&lt;/I&gt; folder in the &lt;I&gt;d:\&lt;/I&gt; parent directory (i.e. &lt;I&gt;d:\newfolder&lt;/I&gt;&lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;BR /&gt;
&lt;BR /&gt;
data _null_;&lt;BR /&gt;
newdirname=dcreate('newfolder', 'd:\');&lt;BR /&gt;
put newdirname=;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
You can use it in the %sysfunc macro function too:&lt;BR /&gt;
&lt;BR /&gt;
%let newdir=%sysfunc(dcreate(newfolder,/tmp));&lt;BR /&gt;
%put &amp;amp;newdir;&lt;BR /&gt;
&lt;BR /&gt;
You should find that dcreate works even when NOXCMD is in effect.    The documentation for the dcreate function at &lt;A href="http://support.sas.com/documentation/cdl/en/sclref/59578/HTML/default/viewer.htm#a000308115.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/sclref/59578/HTML/default/viewer.htm#a000308115.htm&lt;/A&gt;&lt;BR /&gt;
&lt;BR /&gt;
Cheers&lt;BR /&gt;
Paul</description>
      <pubDate>Wed, 08 Jun 2011 23:12:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/creating-a-folder-on-local-drive/m-p/9301#M2234</guid>
      <dc:creator>PaulHomes</dc:creator>
      <dc:date>2011-06-08T23:12:08Z</dc:date>
    </item>
  </channel>
</rss>

