<?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: IBM MAINFRAME renaming a file using sas in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/400595#M25747</link>
    <description>&lt;P&gt;You didn't describe what type of Mainframe you are using. Are you running on MVS, VM/CMS? From the format of the filename it looks like MVS to me.&amp;nbsp; Not sure what you mean by R before the filename, perhaps you are using some type of screen list of file names? Are you using ISPF? Does that still exist? I doubt you are using ROSCOE or WYLBER.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Anyway did you try the RENAME() function in SAS?&lt;/P&gt;
&lt;P&gt;Here is the example from the manual.&amp;nbsp; Just put in your filenames.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;/*
Example 3: Renaming a Directory
The following example renames a directory in the UNIX operating environment.
*/
data _null_;
rc=rename('/local/u/testdir/', '/local/u/oldtestdir', 'file');
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 03 Oct 2017 14:11:21 GMT</pubDate>
    <dc:creator>Tom</dc:creator>
    <dc:date>2017-10-03T14:11:21Z</dc:date>
    <item>
      <title>IBM MAINFRAME renaming a file using sas</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/399852#M25714</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a file name courriel on the ibm mainframe.&lt;/P&gt;&lt;P&gt;ex:&lt;/P&gt;&lt;P&gt;A108.TESTING.COURRIEL&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I can rename this file directly from the mainframe using the command r (stand for rename) on the left margin and give this file a new name.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As I am transfering a new courriel file (updated file)&amp;nbsp;from my pc to the mainframe using a SAS code, I would like to use a sas code in order to rename my mainframe file courriel to cour2017 in order to transfert a new courriel file from my pc while keeping a copy of the original file.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there a way to acheive that?&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Alain&lt;/P&gt;</description>
      <pubDate>Fri, 29 Sep 2017 17:20:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/399852#M25714</guid>
      <dc:creator>alepage</dc:creator>
      <dc:date>2017-09-29T17:20:42Z</dc:date>
    </item>
    <item>
      <title>Re: IBM MAINFRAME renaming a file using sas</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/399874#M25715</link>
      <description>&lt;P&gt;Assuming this command would work on the mainframe:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;r "oldname" "newname"&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You should be able to achieve that in a SAS program using:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;%sysexec r "oldname" "newname" ;&lt;/P&gt;</description>
      <pubDate>Fri, 29 Sep 2017 18:24:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/399874#M25715</guid>
      <dc:creator>Astounding</dc:creator>
      <dc:date>2017-09-29T18:24:22Z</dc:date>
    </item>
    <item>
      <title>Re: IBM MAINFRAME renaming a file using sas</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/400132#M25720</link>
      <description>If you are using PROC UPLOAD for the file transfer you can rename it on the fly by specifying your new file name on the OUTFILE= option.</description>
      <pubDate>Sun, 01 Oct 2017 13:31:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/400132#M25720</guid>
      <dc:creator>LinusH</dc:creator>
      <dc:date>2017-10-01T13:31:32Z</dc:date>
    </item>
    <item>
      <title>Re: IBM MAINFRAME renaming a file using sas</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/400560#M25742</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It is a nice idea but as the original file on the mainframe is courriel, I need to rename this file first, let's say to cour2017 and thereafter, transfert the updated file on the mainframe server.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Alain&lt;/P&gt;</description>
      <pubDate>Tue, 03 Oct 2017 12:08:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/400560#M25742</guid>
      <dc:creator>alepage</dc:creator>
      <dc:date>2017-10-03T12:08:54Z</dc:date>
    </item>
    <item>
      <title>Re: IBM MAINFRAME renaming a file using sas</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/400561#M25743</link>
      <description>&lt;P&gt;I have try your solution but nothing appends.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Alain&lt;/P&gt;</description>
      <pubDate>Tue, 03 Oct 2017 12:09:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/400561#M25743</guid>
      <dc:creator>alepage</dc:creator>
      <dc:date>2017-10-03T12:09:30Z</dc:date>
    </item>
    <item>
      <title>Re: IBM MAINFRAME renaming a file using sas</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/400595#M25747</link>
      <description>&lt;P&gt;You didn't describe what type of Mainframe you are using. Are you running on MVS, VM/CMS? From the format of the filename it looks like MVS to me.&amp;nbsp; Not sure what you mean by R before the filename, perhaps you are using some type of screen list of file names? Are you using ISPF? Does that still exist? I doubt you are using ROSCOE or WYLBER.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Anyway did you try the RENAME() function in SAS?&lt;/P&gt;
&lt;P&gt;Here is the example from the manual.&amp;nbsp; Just put in your filenames.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;/*
Example 3: Renaming a Directory
The following example renames a directory in the UNIX operating environment.
*/
data _null_;
rc=rename('/local/u/testdir/', '/local/u/oldtestdir', 'file');
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Oct 2017 14:11:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/400595#M25747</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2017-10-03T14:11:21Z</dc:date>
    </item>
    <item>
      <title>Re: IBM MAINFRAME renaming a file using sas</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/470367#M30515</link>
      <description>&lt;P&gt;Did you figure out how to rename mainframe file using SAS? Please share your solution.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks and best regards.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Rajesh.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jun 2018 16:29:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/470367#M30515</guid>
      <dc:creator>bhandari9</dc:creator>
      <dc:date>2018-06-14T16:29:13Z</dc:date>
    </item>
    <item>
      <title>Re: IBM MAINFRAME renaming a file using sas</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/475477#M30839</link>
      <description>&lt;P&gt;unfortunately,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have switch to another job and the working environment is different.&amp;nbsp; I can't test myself the proposed code.&lt;/P&gt;&lt;P&gt;I might ask a colleague to do so.&lt;/P&gt;&lt;P&gt;I will let your know if it works.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Alain.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jul 2018 19:05:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/IBM-MAINFRAME-renaming-a-file-using-sas/m-p/475477#M30839</guid>
      <dc:creator>alepage</dc:creator>
      <dc:date>2018-07-04T19:05:35Z</dc:date>
    </item>
  </channel>
</rss>

