<?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 SAS Viya create new folder programatically in SAS Viya</title>
    <link>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895219#M2021</link>
    <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;%let folder_name = 'foldeCBA'; 
%let path = '/home/u47498320/SAS Projects/folder1'; 

data null;
 new=dcreate(&amp;amp;folder_name, &amp;amp;path);
run;&lt;/PRE&gt;&lt;P&gt;I am trying to run this code in SAS Viya, it has no errors/ warnings but did not manage to create a new folder named &lt;EM&gt;foldeCBA. &lt;/EM&gt;This works fine in SAS Studio. I suspect its due to how the data are stored/ location in SAS Viya. Any ideas on this?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 21 Sep 2023 10:49:18 GMT</pubDate>
    <dc:creator>hanssen</dc:creator>
    <dc:date>2023-09-21T10:49:18Z</dc:date>
    <item>
      <title>SAS Viya create new folder programatically</title>
      <link>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895219#M2021</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;%let folder_name = 'foldeCBA'; 
%let path = '/home/u47498320/SAS Projects/folder1'; 

data null;
 new=dcreate(&amp;amp;folder_name, &amp;amp;path);
run;&lt;/PRE&gt;&lt;P&gt;I am trying to run this code in SAS Viya, it has no errors/ warnings but did not manage to create a new folder named &lt;EM&gt;foldeCBA. &lt;/EM&gt;This works fine in SAS Studio. I suspect its due to how the data are stored/ location in SAS Viya. Any ideas on this?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 21 Sep 2023 10:49:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895219#M2021</guid>
      <dc:creator>hanssen</dc:creator>
      <dc:date>2023-09-21T10:49:18Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Viya create new folder programatically</title>
      <link>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895253#M2024</link>
      <description>Which version of Viya? The DCREATE documentation indicates you need to pull SYSMSG to see the failure reason. For example:&lt;BR /&gt;%let folder_name = 'foldeCBA'; &lt;BR /&gt;%let path = '/home/u47498320/SAS Projects/folder1'; &lt;BR /&gt;data _null_;&lt;BR /&gt;	new=dcreate(&amp;amp;folder_name,&amp;amp;path);&lt;BR /&gt;	msg=sysmsg();&lt;BR /&gt;	put msg=;&lt;BR /&gt;run;&lt;BR /&gt;&lt;BR /&gt;DCREATE Function&lt;BR /&gt;&lt;A href="https://go.documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/lefunctionsref/p1aj29pf4cxnirn15q5hmf0tv438.htm" target="_blank"&gt;https://go.documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/lefunctionsref/p1aj29pf4cxnirn15q5hmf0tv438.htm&lt;/A&gt;&lt;BR /&gt;SYSMSG Function&lt;BR /&gt;&lt;A href="https://go.documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/lefunctionsref/p08jvlsdb0wuu1n15jm7tvhg0yhx.htm" target="_blank"&gt;https://go.documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/lefunctionsref/p08jvlsdb0wuu1n15jm7tvhg0yhx.htm&lt;/A&gt;</description>
      <pubDate>Thu, 21 Sep 2023 13:32:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895253#M2024</guid>
      <dc:creator>gwootton</dc:creator>
      <dc:date>2023-09-21T13:32:29Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Viya create new folder programatically</title>
      <link>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895365#M2026</link>
      <description>&lt;PRE&gt;msg=ERROR: Physical file does not exist, /home/u47498320/SAS Projects/folder1&lt;/PRE&gt;&lt;P&gt;My SAS version is&amp;nbsp;V.03.05M0P11112019 and I got this message. I was wondering how could I check and go into the correct file path in SAS Viya so that I could create the folder?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 22 Sep 2023 01:06:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895365#M2026</guid>
      <dc:creator>hanssen</dc:creator>
      <dc:date>2023-09-22T01:06:38Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Viya create new folder programatically</title>
      <link>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895366#M2027</link>
      <description>The error message is saying the path where you are trying to create the folder doesn't exist. In SAS Studio  in Viya 3.5 you may have the full system root available or it may start at your home directory. You could also sign on to the compute server host directly to identify the path.</description>
      <pubDate>Fri, 22 Sep 2023 01:12:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895366#M2027</guid>
      <dc:creator>gwootton</dc:creator>
      <dc:date>2023-09-22T01:12:24Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Viya create new folder programatically</title>
      <link>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895368#M2028</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/78975"&gt;@gwootton&lt;/a&gt;. Just curious, do you have any ideas on SAS commands that could get the current directory? I would like to try using SAS commands instead of logging into the server&lt;/P&gt;</description>
      <pubDate>Fri, 22 Sep 2023 01:18:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895368#M2028</guid>
      <dc:creator>hanssen</dc:creator>
      <dc:date>2023-09-22T01:18:03Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Viya create new folder programatically</title>
      <link>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895437#M2029</link>
      <description>You could use these commands to get your home directory and the current working directory from environment variables:&lt;BR /&gt;&lt;BR /&gt;%put %SYSGET(HOME);&lt;BR /&gt;%put %SYSGET(PWD);</description>
      <pubDate>Fri, 22 Sep 2023 12:47:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895437#M2029</guid>
      <dc:creator>gwootton</dc:creator>
      <dc:date>2023-09-22T12:47:20Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Viya create new folder programatically</title>
      <link>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895621#M2033</link>
      <description>&lt;P&gt;I am still unable to resolve finding the correct folder path. However, I have decided to go with&amp;nbsp;&lt;A href="https://github.com/sasjs/core/tree/main" target="_self"&gt;&lt;SPAN&gt;Macro Core library&lt;/SPAN&gt;&lt;/A&gt;&amp;nbsp;&lt;SPAN&gt;and it works fine for my problem.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;filename mc url "https://raw.githubusercontent.com/sasjs/core/main/all.sas";
%inc mc;

%mv_createfolder(path=/Users/ch/My Folder/TestFolder)&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 25 Sep 2023 07:21:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Viya/SAS-Viya-create-new-folder-programatically/m-p/895621#M2033</guid>
      <dc:creator>hanssen</dc:creator>
      <dc:date>2023-09-25T07:21:19Z</dc:date>
    </item>
  </channel>
</rss>

