<?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: Compile file names into a single batch file in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215258#M39739</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This worked perfectly except it compressed the file name and deleted the spaces. The true path is C:\Users\KMarino\Dropbox\Dissertation\Data Generation\For Dissertation\Simulation Syntax\filename.flexMIRT. &lt;/P&gt;&lt;P&gt;It deleted the space between "Data Generation", "For Dissertation" and "Simulation Syntax". Is there a way to avoid that?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 15 May 2015 12:43:22 GMT</pubDate>
    <dc:creator>KateM</dc:creator>
    <dc:date>2015-05-15T12:43:22Z</dc:date>
    <item>
      <title>Compile file names into a single batch file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215254#M39735</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I used SAS to create 60,000 flexMIRT syntax files for a simulation study. Now I need to compile those file names into a single csv batch file. &lt;SPAN style="color: #222222; font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: #ffffff;"&gt;I've created the batch macro below but I keep overwriting the batch file instead of amending it as I try and loop through the file names. I think I need to create a DO loop within the batch macro. The batch file should look like: &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800080; font-size: 13.3333330154419px; background-color: #ffffff; font-family: 'Courier New';"&gt;C:\Users\KMarino\300_10_0.11_10_1.flexmirt&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800080; font-size: 13.3333330154419px; background-color: #ffffff; font-family: 'Courier New';"&gt;C:\Users\KMarino\300_10_0.11_10_2.flexmirt&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800080; font-size: 13.3333330154419px; background-color: #ffffff; font-family: 'Courier New';"&gt;C:\Users\KMarino\300_10_0.11_10_3.flexmirt&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800080; font-size: 13.3333330154419px; background-color: #ffffff; font-family: 'Courier New';"&gt;......&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800080; font-size: 13.3333330154419px; background-color: #ffffff; font-family: 'Courier New';"&gt;C:\Users\KMarino\300_10_0.11_10_250.flexmirt&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800080; font-size: 13.3333330154419px; background-color: #ffffff; font-family: 'Courier New';"&gt;.....&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800080; font-size: 13.3333330154419px; background-color: #ffffff; font-family: 'Courier New';"&gt;C:\Users\KMarino\1000_10_0.11_10_1.flexmirt&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800080; font-size: 13.3333330154419px; background-color: #ffffff; font-family: 'Courier New';"&gt;.....&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800080; font-size: 13.3333330154419px; background-color: #ffffff; font-family: 'Courier New';"&gt;C:\Users\KMarino\300_10_0.11_10_250.flexmirt&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800080; font-size: 13.3333330154419px; background-color: #ffffff; font-family: 'Courier New';"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #222222; font-size: 12.8000001907349px; background-color: #ffffff; font-family: arial, sans-serif;"&gt;How can I modify the macro below to appropriately compile all the files?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800080; font-size: 13.3333330154419px; background-color: #ffffff; font-family: 'Courier New';"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: navy; font-size: 10pt; font-family: 'Courier New'; background-position: initial;"&gt;%MACRO&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; batch(I=, ss=, cl=, bv=, it=, rep=);&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;DATA _NULL_;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; FILE &lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;"C:\Users\KMarino\Dropbox\Dissertation\Data Generation\For Dissertation\SAS Control Files\flexMIRTsim.BATRUN.csv"&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;PUT&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; #&amp;amp;I @&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; font-family: 'Courier New'; background-position: initial;"&gt;1 &lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;"C:\Users\KMarino\&amp;amp;ss._&amp;amp;cl._&amp;amp;bv._&amp;amp;it._&amp;amp;rep..flexMIRT"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;RUN;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: navy; font-size: 10pt; font-family: 'Courier New'; background-position: initial;"&gt;%mend&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; batch;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: navy; font-size: 10pt; font-family: 'Courier New'; background-position: initial;"&gt;data&lt;/STRONG&gt; &lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;_null_&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue; background-color: #ffffff; background-position: initial;"&gt;DO&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt; ss=&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;300&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;1000&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;5000&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue; background-color: #ffffff; background-position: initial;"&gt;DO&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt; cl=&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;10&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;60&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;100&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;150&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="im" style="color: #500050;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;DO&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; it=&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; font-family: 'Courier New'; background-position: initial;"&gt;10&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; font-family: 'Courier New'; background-position: initial;"&gt;20&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; font-family: 'Courier New'; background-position: initial;"&gt;50&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; font-family: 'Courier New'; background-position: initial;"&gt;70&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue; background-color: #ffffff; background-position: initial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DO&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt; BV=&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;0.053&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;0.11&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;0.25&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;0.43&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;1.00&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue; background-color: #ffffff; background-position: initial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DO&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt; it=&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;10&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;20&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;50&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;, &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; background-color: #ffffff; font-family: 'Courier New'; background-position: initial;"&gt;70&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;Do&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; rep=&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; font-family: 'Courier New'; background-position: initial;"&gt;1&lt;/STRONG&gt; &lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;to&lt;/SPAN&gt; &lt;STRONG style="color: teal; font-size: 10pt; font-family: 'Courier New'; background-position: initial;"&gt;250&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; _N_+&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; font-family: 'Courier New'; background-position: initial;"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;call&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; execute (catt(&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;'%batch (I='&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;|| put(_N_+&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; font-family: 'Courier New'; background-position: initial;"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;,&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10pt; font-family: 'Courier New'; background-position: initial;"&gt;2.&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;)||&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;', ss='&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;, ss ,&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;', cl='&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;, cl ,&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;', bv='&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;,bv,&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;', it='&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;,it,&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;', rep='&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;,rep,&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;')'&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;)) ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;end&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: #3366ff; background-position: initial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; end;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: #3366ff; background-position: initial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; end;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: #3366ff; background-position: initial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; end;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: #3366ff; background-position: initial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; end;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: #3366ff; background-position: initial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; end;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: #3366ff; background-position: initial;"&gt;run;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="im" style="color: #500050;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 May 2015 20:13:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215254#M39735</guid>
      <dc:creator>KateM</dc:creator>
      <dc:date>2015-05-14T20:13:14Z</dc:date>
    </item>
    <item>
      <title>Re: Compile file names into a single batch file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215255#M39736</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If this a program that will run under SAS it may be easier to use something like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%include "&lt;SPAN style="color: #800080; font-family: 'Courier New'; font-size: 13.33px; background-color: #ffffff;"&gt;C:\Users\KMarino\*.flexmirt";&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 May 2015 21:40:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215255#M39736</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2015-05-14T21:40:58Z</dc:date>
    </item>
    <item>
      <title>Re: Compile file names into a single batch file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215256#M39737</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Add the operand "MOD" to your FILE statement - it will be ignored by SAS on the first execution of the invoked DATA _NULL_ step.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Scott Barry&lt;BR /&gt;SBBWorks, Inc.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 May 2015 22:59:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215256#M39737</guid>
      <dc:creator>sbb</dc:creator>
      <dc:date>2015-05-14T22:59:58Z</dc:date>
    </item>
    <item>
      <title>Re: Compile file names into a single batch file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215257#M39738</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Alternatively it could be done in a single data step without using a macro, something like this :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;data _null_;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;FILE "C:\Users\KMarino\Dropbox\Dissertation\Data Generation\For Dissertation\SAS Control Files\flexMIRTsim.BATRUN.csv";&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;DO ss='300', '1000', '5000';&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt; DO cl='10', '60', '100', '150';&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp; DO it='10', '20', '50', '70';&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp; DO BV='0.053', '0.11', '0.25', '0.43', '1.00';&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; DO it='10', '20', '50', '70';&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Do rep=1 to 250;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string= compress('C:\Users\KMarino\' !! ss !! '_' !! cl !! '_' !! bv !! '_' !! it !! '_' !! put(rep, 3.) !! '.flexMIRT', ' ');&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; PUT&amp;nbsp; @1 string;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; end;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; end;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp; end;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp; end;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt; end;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;end;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;run;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 May 2015 01:02:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215257#M39738</guid>
      <dc:creator>dkb</dc:creator>
      <dc:date>2015-05-15T01:02:57Z</dc:date>
    </item>
    <item>
      <title>Re: Compile file names into a single batch file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215258#M39739</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This worked perfectly except it compressed the file name and deleted the spaces. The true path is C:\Users\KMarino\Dropbox\Dissertation\Data Generation\For Dissertation\Simulation Syntax\filename.flexMIRT. &lt;/P&gt;&lt;P&gt;It deleted the space between "Data Generation", "For Dissertation" and "Simulation Syntax". Is there a way to avoid that?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 May 2015 12:43:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215258#M39739</guid>
      <dc:creator>KateM</dc:creator>
      <dc:date>2015-05-15T12:43:22Z</dc:date>
    </item>
    <item>
      <title>Re: Compile file names into a single batch file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215259#M39740</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You might thing about what is happening when you COMPRESS.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 May 2015 13:10:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215259#M39740</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2015-05-15T13:10:16Z</dc:date>
    </item>
    <item>
      <title>Re: Compile file names into a single batch file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215260#M39741</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;1) Why not make the list while you make the files?&amp;nbsp; Either as a data set or into the text file.&lt;/P&gt;&lt;P&gt;2) Since you already have the files why not just use DIR command to get the list?&amp;nbsp; Does the order matter?&amp;nbsp; And if so is it different than the order that DIR will return.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data _null_;&lt;/P&gt;&lt;P&gt;&amp;nbsp; file&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: purple; background-color: #ffffff; background-position: initial;"&gt;"C:\Users\KMarino\Dropbox\Dissertation\Data Generation\For Dissertation\SAS Control Files\flexMIRTsim.BATRUN.csv"&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black; background-color: #ffffff; background-position: initial;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;infile 'dir /b &lt;SPAN style="color: #800080; font-family: 'Courier New'; font-size: 13.3333330154419px; background-color: #ffffff;"&gt;C:\Users\KMarino\*.flexmirt' pipe;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; input;&lt;/P&gt;&lt;P&gt;&amp;nbsp; put _infile_;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 May 2015 16:16:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215260#M39741</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2015-05-15T16:16:21Z</dc:date>
    </item>
    <item>
      <title>Re: Compile file names into a single batch file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215261#M39742</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use the mod option with the file-statement when you do not want to overwrite but append the csv file &lt;A href="http://support.sas.com/documentation/cdl/en/lestmtsref/67407/HTML/default/viewer.htm#n15o12lpyoe4gfn1y1vcp6xs6966.htm" title="http://support.sas.com/documentation/cdl/en/lestmtsref/67407/HTML/default/viewer.htm#n15o12lpyoe4gfn1y1vcp6xs6966.htm"&gt;SAS(R) 9.4 Statements: Reference, Third Edition&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 May 2015 17:04:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215261#M39742</guid>
      <dc:creator>jakarman</dc:creator>
      <dc:date>2015-05-15T17:04:12Z</dc:date>
    </item>
    <item>
      <title>Re: Compile file names into a single batch file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215262#M39743</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for all the suggestions! The MOD statement worked after some further modification of the original syntax but now I've also learned some new commands from the other suggestions. Thanks so much for the help!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2015 14:53:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compile-file-names-into-a-single-batch-file/m-p/215262#M39743</guid>
      <dc:creator>KateM</dc:creator>
      <dc:date>2015-05-18T14:53:42Z</dc:date>
    </item>
  </channel>
</rss>

