<?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: Obtaining &amp;quot;Shell Output&amp;quot; in sas with SAS function &amp;quot;System&amp;quot;, &amp;quot;X&amp;quot; or in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269132#M53311</link>
    <description>&lt;P&gt;I can't test it . so I can't say YES.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My thought is setting up a schedule task , launch it at every hour or half-hour, and run the SAS script we just suggested.&lt;/P&gt;</description>
    <pubDate>Mon, 09 May 2016 09:42:23 GMT</pubDate>
    <dc:creator>Ksharp</dc:creator>
    <dc:date>2016-05-09T09:42:23Z</dc:date>
    <item>
      <title>Obtaining "Shell Output" in sas with SAS function "System", "X" or "Call System"</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269120#M53301</link>
      <description>&lt;P&gt;Hallo,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is there any way in sas to obtain Shell output inside SAS. For example, I am trying to obtain the output of Unix Shell command "top" (which is in the attached). Is there any way to do it in SAS ? I have seen command line calls can be executed using the sas functions like "System()" or "X". But the Question is to get the output inside SAS along with the executon.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks and regards&lt;/P&gt;
&lt;P&gt;Ehsan&lt;/P&gt;&lt;BR /&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/12524i9FB86C0E53F68922/image-size/large?v=1.0&amp;amp;px=600" border="0" alt="Output_of_TOP.jpg" title="Output_of_TOP.jpg" /&gt;</description>
      <pubDate>Mon, 09 May 2016 08:35:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269120#M53301</guid>
      <dc:creator>ehsanmath</dc:creator>
      <dc:date>2016-05-09T08:35:21Z</dc:date>
    </item>
    <item>
      <title>Re: Obtaining "Shell Output" in sas with SAS function "System", "X" or</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269121#M53302</link>
      <description>&lt;P&gt;Set your OS command as a filename, then datastep read it in, in this example I use the Windows, and below I make an attempt to show the top even though I don't use Unix:&lt;/P&gt;
&lt;PRE&gt;filename mytmp pipe 'dir "c:\temp" /b';

data dir_list;
  length buffer $200;
  infile mytmp dlm="¬";
  input buffer;
run;&lt;/PRE&gt;
&lt;PRE&gt;filename mytmp pipe 'top';&lt;BR /&gt;data ...&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 09 May 2016 08:39:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269121#M53302</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2016-05-09T08:39:04Z</dc:date>
    </item>
    <item>
      <title>Re: Obtaining "Shell Output" in sas with SAS function "System", "X" or</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269125#M53304</link>
      <description>&lt;P&gt;Another way is to redirect the output of Shell Command into a file :&lt;/P&gt;
&lt;P&gt;$ls *.csv &lt;STRONG&gt;&amp;nbsp;&amp;gt;&lt;/STRONG&gt; &amp;nbsp;/home/etc/output.txt&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;and then import it into SAS:&lt;/P&gt;
&lt;P&gt;filename x '&lt;SPAN&gt;/home/etc/output.txt&lt;/SPAN&gt;';&lt;/P&gt;
&lt;P&gt;data _null_;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;infile x;&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;</description>
      <pubDate>Mon, 09 May 2016 08:53:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269125#M53304</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2016-05-09T08:53:01Z</dc:date>
    </item>
    <item>
      <title>Re: Obtaining "Shell Output" in sas with SAS function "System", "X" or</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269126#M53305</link>
      <description>&lt;P&gt;whats the equivalant to "top" in Windows (DOS) ?&lt;/P&gt;
&lt;P&gt;I check again, my SAS is running on Windows.&lt;/P&gt;</description>
      <pubDate>Mon, 09 May 2016 09:11:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269126#M53305</guid>
      <dc:creator>ehsanmath</dc:creator>
      <dc:date>2016-05-09T09:11:47Z</dc:date>
    </item>
    <item>
      <title>Re: Obtaining "Shell Output" in sas with SAS function "System", "X" or</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269127#M53306</link>
      <description>&lt;P&gt;Actually, I am thinking to monitor RAM and CPU Usage inside SAS during computation. Is it possible ?&lt;/P&gt;</description>
      <pubDate>Mon, 09 May 2016 09:15:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269127#M53306</guid>
      <dc:creator>ehsanmath</dc:creator>
      <dc:date>2016-05-09T09:15:52Z</dc:date>
    </item>
    <item>
      <title>Re: Obtaining "Shell Output" in sas with SAS function "System", "X" or</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269130#M53309</link>
      <description>&lt;P&gt;You could try the mem command:&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.computerhope.com/memhlp.htm" target="_blank"&gt;http://www.computerhope.com/memhlp.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You may be better off getting some system monitor sotware though, more functionality/control.&lt;/P&gt;</description>
      <pubDate>Mon, 09 May 2016 09:34:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269130#M53309</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2016-05-09T09:34:11Z</dc:date>
    </item>
    <item>
      <title>Re: Obtaining "Shell Output" in sas with SAS function "System", "X" or</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269132#M53311</link>
      <description>&lt;P&gt;I can't test it . so I can't say YES.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My thought is setting up a schedule task , launch it at every hour or half-hour, and run the SAS script we just suggested.&lt;/P&gt;</description>
      <pubDate>Mon, 09 May 2016 09:42:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269132#M53311</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2016-05-09T09:42:23Z</dc:date>
    </item>
    <item>
      <title>Re: Obtaining "Shell Output" in sas with SAS function "System", "X" or</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269152#M53314</link>
      <description>&lt;P&gt;Not sure how you wish to do that? In the same SAS session? Don't think that's possible, and&amp;nbsp;why?&lt;/P&gt;
&lt;P&gt;SAS interacts/uses system resources so monitoring&amp;nbsp;should take place outside SAS.&lt;/P&gt;
&lt;P&gt;For statistical purposes, you could use SAS to collect the figures, like options fullstimer, or ARM stuff.&lt;/P&gt;</description>
      <pubDate>Mon, 09 May 2016 12:30:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Obtaining-quot-Shell-Output-quot-in-sas-with-SAS-function-quot/m-p/269152#M53314</guid>
      <dc:creator>LinusH</dc:creator>
      <dc:date>2016-05-09T12:30:11Z</dc:date>
    </item>
  </channel>
</rss>

