<?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 to use fileexist function in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58654#M12739</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Peter,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The suggested code from FriedEgg did not used the datalines statement.&amp;nbsp; After switching to FriedEgg's code, the example ran properly for me.&amp;nbsp; So, both FriedEgg and Peter have produced working examples for me.&amp;nbsp; One uses the datalines statement and one does not.&amp;nbsp; Thank you both for providing me with a solution!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 31 Aug 2011 20:40:27 GMT</pubDate>
    <dc:creator>WesBarris</dc:creator>
    <dc:date>2011-08-31T20:40:27Z</dc:date>
    <item>
      <title>How to use fileexist function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58645#M12730</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I would like to test for the existance of a file.&amp;nbsp; If the file exists I would like to import its contents.&amp;nbsp; If the file does not exist I would like to create a dataset with some variables.&amp;nbsp; I'm not sure how to code this.&amp;nbsp; Here is what I have tried:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data null;&lt;/P&gt;&lt;P&gt;if fileexist("s:\L57MG176\L5776D3.XLS") then&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; call execute('proc import out=work.ulsound1 datafile="s:\L57MG176\L5776D3.XLS" dbms=excel5 replace; sheet="L5776D3"; getnames=yes;');&lt;/P&gt;&lt;P&gt;else&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; call execute('data work.ulsound1; input cid aaa; datalines;0 0;');&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;proc print data=work.ulsound1;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This appears to work if the file is found but I don't think that the datalines part is working when the file is not found.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 15:54:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58645#M12730</guid>
      <dc:creator>WesBarris</dc:creator>
      <dc:date>2011-08-31T15:54:43Z</dc:date>
    </item>
    <item>
      <title>How to use fileexist function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58646#M12731</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The problem is with your syntax in the data step you are calling from the file not exist event.&amp;nbsp; The datalines statement will not work properly without the proper spacing.&amp;nbsp; You should be producing a emtpy dataset rather than a dataset containing a single row with your datalines info.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call execute('data ulsound1; cid=0; aaa=0;');&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 16:08:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58646#M12731</guid>
      <dc:creator>FriedEgg</dc:creator>
      <dc:date>2011-08-31T16:08:22Z</dc:date>
    </item>
    <item>
      <title>How to use fileexist function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58647#M12732</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I agree with FriedEgg but think that it will run (better?) if it includes a run statement.&amp;nbsp; i.e.,&lt;/P&gt;&lt;P&gt;call execute('data ulsound1; cid=0; aaa=0;run;');&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 16:12:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58647#M12732</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2011-08-31T16:12:23Z</dc:date>
    </item>
    <item>
      <title>How to use fileexist function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58648#M12733</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; not a run statement I think, but if there is some need to make these datalines take effect, then you need three call execute() statements to separate the datalines from the semi-colons before and after&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: navy; font-size: 9pt; background-color: white; font-family: 'Courier New';"&gt;data&lt;/STRONG&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black; font-size: 9pt;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;SPAN style="background-color: white; font-family: 'Courier New'; color: blue; font-size: 9pt;"&gt;call&lt;/SPAN&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black; font-size: 9pt;"&gt; execute( &lt;/SPAN&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: purple; font-size: 9pt;"&gt;'data; input a b c; cards;'&lt;/SPAN&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black; font-size: 9pt;"&gt;);&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;SPAN style="background-color: white; font-family: 'Courier New'; color: blue; font-size: 9pt;"&gt;call&lt;/SPAN&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black; font-size: 9pt;"&gt; execute( &lt;/SPAN&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: purple; font-size: 9pt;"&gt;' 1 2 3 '&lt;/SPAN&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black; font-size: 9pt;"&gt;) ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;SPAN style="background-color: white; font-family: 'Courier New'; color: blue; font-size: 9pt;"&gt;call&lt;/SPAN&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black; font-size: 9pt;"&gt; execute( &lt;/SPAN&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: purple; font-size: 9pt;"&gt;';'&lt;/SPAN&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black; font-size: 9pt;"&gt; );&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: navy; font-size: 9pt; background-color: white; font-family: 'Courier New';"&gt;run&lt;/STRONG&gt;;&lt;/P&gt;&lt;P&gt;works&lt;/P&gt;&lt;P&gt;but attaching the ' 1 2 3 ' to the semi-colons either before or after fails&lt;/P&gt;&lt;P&gt;The working solution produced this log&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black;"&gt;25&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; data null;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black;"&gt;26&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if fileexist("s:\L57MG176\L5776D3.XLS") then&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black;"&gt;27&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; call execute('proc import out=work.ulsound1 datafile="s:\L57MG176\L5776D3.XLS" dbms=excel5 replace;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black;"&gt;27&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ! sheet="L5776D3"; getnames=yes;');&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black;"&gt;28&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; else do ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black;"&gt;29&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; call execute('data work.ulsound1; input cid aaa; datalines;');&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black;"&gt;30&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; call execute('0 0');&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black;"&gt;31&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; call execute(';');&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: blue;"&gt;2&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;&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; The SAS System&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: blue;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black;"&gt;32&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="background-color: white; font-family: 'Courier New'; color: black;"&gt;33&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; run;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;NOTE: The data set WORK.NULL has 1 observations and 0 variables.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;NOTE: DATA statement used (Total process time):&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; real time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.02 seconds&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cpu time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.01 seconds&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;NOTE: CALL EXECUTE generated line.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black;"&gt;1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; + data work.ulsound1; input cid aaa; datalines;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;NOTE: The data set WORK.ULSOUND1 has 1 observations and 2 variables.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;NOTE: DATA statement used (Total process time):&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; real time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.01 seconds&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cpu time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.01 seconds&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black;"&gt;3&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; + ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black;"&gt;35&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; proc print data=work.ulsound1;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: black;"&gt;36&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; run;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;NOTE: There were 1 observations read from the data set WORK.ULSOUND1.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;NOTE: PROCEDURE PRINT used (Total process time):&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: white; font-family: 'Courier New'; color: green;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; real time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.12 seconds&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="SASCode"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cpu time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.00 seconds&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 20:03:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58648#M12733</guid>
      <dc:creator>Peter_C</dc:creator>
      <dc:date>2011-08-31T20:03:39Z</dc:date>
    </item>
    <item>
      <title>How to use fileexist function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58649#M12734</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Peter,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It ran for me with just the one statement as long as it included a run statement.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 20:10:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58649#M12734</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2011-08-31T20:10:19Z</dc:date>
    </item>
    <item>
      <title>How to use fileexist function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58650#M12735</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; my testing with run; on the datalines version, produced no observation.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;guess I'm just demonstrating the message from "FriedEgg" &lt;/P&gt;&lt;P&gt;"datalines statement will not work properly without the proper spacing"&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 20:19:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58650#M12735</guid>
      <dc:creator>Peter_C</dc:creator>
      <dc:date>2011-08-31T20:19:00Z</dc:date>
    </item>
    <item>
      <title>How to use fileexist function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58651#M12736</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you just want one observation you could dispense with the CARDS.&amp;nbsp; You could use a RETAIN statement.&amp;nbsp; Or if you want to initialize everything to the same value you could use an ARRAY statement and take advantage of the NN*value syntax of the initial values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data ulsound1;&lt;/P&gt;&lt;P&gt; array _num cid aaa (2*0);&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 20:20:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58651#M12736</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2011-08-31T20:20:54Z</dc:date>
    </item>
    <item>
      <title>How to use fileexist function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58652#M12737</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, Peter example of using the multiple execute statements provides the proper output for the datalines statement so it is another way of accomplishing the task.&amp;nbsp; The inclusion of the 'run' statment, while providing a properly closed block but should not effect the resulting output.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 20:23:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58652#M12737</guid>
      <dc:creator>FriedEgg</dc:creator>
      <dc:date>2011-08-31T20:23:58Z</dc:date>
    </item>
    <item>
      <title>How to use fileexist function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58653#M12738</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes. I can confirm that it ran for me too as Art described.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 20:37:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58653#M12738</guid>
      <dc:creator>WesBarris</dc:creator>
      <dc:date>2011-08-31T20:37:40Z</dc:date>
    </item>
    <item>
      <title>How to use fileexist function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58654#M12739</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Peter,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The suggested code from FriedEgg did not used the datalines statement.&amp;nbsp; After switching to FriedEgg's code, the example ran properly for me.&amp;nbsp; So, both FriedEgg and Peter have produced working examples for me.&amp;nbsp; One uses the datalines statement and one does not.&amp;nbsp; Thank you both for providing me with a solution!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 20:40:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58654#M12739</guid>
      <dc:creator>WesBarris</dc:creator>
      <dc:date>2011-08-31T20:40:27Z</dc:date>
    </item>
    <item>
      <title>How to use fileexist function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58655#M12740</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; thank you FriedEgg&lt;/P&gt;&lt;P&gt;I too wish SAS steps had memorable and consistent block/step termination, but like a natural language, SAS has a lot of varieties and exceptions for the end of a step, to the point that I prefer to use what is appropriate. For example RUN does something special and does not end PROC IML (which needs quit;)&lt;/P&gt;&lt;P&gt;There is also something peculiar about the PROC FORMAT which sometimes (during error handling) rejects run; and seeks quit;&lt;/P&gt;&lt;P&gt;I don't recommend run; after datalines.&lt;/P&gt;&lt;P&gt;(but that's just me) &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 20:45:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58655#M12740</guid>
      <dc:creator>Peter_C</dc:creator>
      <dc:date>2011-08-31T20:45:29Z</dc:date>
    </item>
    <item>
      <title>How to use fileexist function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58656#M12741</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have never experienced a behavior like you described with PROC FORMAT, do you have any links to provide me with some refernece to read on the issue?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 21:04:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58656#M12741</guid>
      <dc:creator>FriedEgg</dc:creator>
      <dc:date>2011-08-31T21:04:00Z</dc:date>
    </item>
    <item>
      <title>How to use fileexist function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58657#M12742</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE __jive_macro_name="quote" class="jive_text_macro jive_macro_quote"&gt;&lt;P&gt;FriedEgg wrote:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have never experienced a behavior like you described with PROC FORMAT, do you have any links to provide me with some refernece to read on the issue?&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;nope&lt;/P&gt;&lt;P&gt;sorry FriedEgg, I have no link nor current evidence. &lt;/P&gt;&lt;P&gt;But some releases-ago, an error popped up from a mixture of cntlin, cntlout and select statements that were unable to find the target member. I ran it several times to be sure. It may be a defect that has been removed since then, but I am cautious with that PROC (while it is still one of my favourites)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 21:46:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-use-fileexist-function/m-p/58657#M12742</guid>
      <dc:creator>Peter_C</dc:creator>
      <dc:date>2011-08-31T21:46:53Z</dc:date>
    </item>
  </channel>
</rss>

